MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / reshape_heads

Function reshape_heads

src/models/ace_step/diffusion.cpp:99–109  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97 const core::TensorValue & q_heads,
98 const core::TensorValue & k_heads,
99 const core::TensorValue & v_heads,
100 int64_t dim,
101 const std::optional<core::TensorValue> & attention_mask,
102 core::BackendType backend_type) {
103 (void)backend_type;
104 return modules::ScaledDotProductAttentionModule({
105 dim,
106 modules::ScaledDotProductAttentionLowering::Explicit,
107 GGML_PREC_F32,
108 }).build(ctx, q_heads, k_heads, v_heads, attention_mask);
109}
110
111core::TensorValue build_attention(
112 core::ModuleBuildContext & ctx,

Callers 2

build_attentionFunction · 0.70
buildMethod · 0.70

Calls 2

reshape_tensorFunction · 0.85
ensure_contiguousFunction · 0.70

Tested by

no test coverage detected