MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / ggml_are_same_shape

Function ggml_are_same_shape

ggml.c:2118–2126  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2116}
2117
2118bool ggml_are_same_shape(const struct ggml_tensor * t0, const struct ggml_tensor * t1) {
2119 static_assert(GGML_MAX_DIMS == 4, "GGML_MAX_DIMS is not 4 - update this function");
2120
2121 return
2122 (t0->ne[0] == t1->ne[0] ) &&
2123 (t0->ne[1] == t1->ne[1] ) &&
2124 (t0->ne[2] == t1->ne[2] ) &&
2125 (t0->ne[3] == t1->ne[3] );
2126}
2127
2128// check if t1 can be represented as a repeatition of t0
2129static inline bool ggml_can_repeat(const struct ggml_tensor * t0, const struct ggml_tensor * t1) {

Callers 15

ggml_add_implFunction · 0.70
ggml_add_cast_implFunction · 0.70
ggml_add_idx_implFunction · 0.70
ggml_sub_implFunction · 0.70
ggml_mul_implFunction · 0.70
ggml_div_implFunction · 0.70
ggml_repeat_backFunction · 0.70
ggml_add_rel_pos_implFunction · 0.70
ggml_map_binary_impl_f32Function · 0.70
ggml_cross_entropy_lossFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected