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

Function ggml_nelements

ggml.c:1944–1948  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1942}
1943
1944int64_t ggml_nelements(const struct ggml_tensor * tensor) {
1945 static_assert(GGML_MAX_DIMS == 4, "GGML_MAX_DIMS is not 4 - update this function");
1946
1947 return tensor->ne[0]*tensor->ne[1]*tensor->ne[2]*tensor->ne[3];
1948}
1949
1950int64_t ggml_nrows(const struct ggml_tensor * tensor) {
1951 static_assert(GGML_MAX_DIMS == 4, "GGML_MAX_DIMS is not 4 - update this function");

Callers 15

ggml_acc_implFunction · 0.70
ggml_set_implFunction · 0.70
ggml_cpy_implFunction · 0.70
ggml_cont_4dFunction · 0.70
ggml_reshapeFunction · 0.70
ggml_reshape_1dFunction · 0.70
ggml_reshape_2dFunction · 0.70
ggml_reshape_3dFunction · 0.70
ggml_reshape_4dFunction · 0.70
ggml_flash_attn_backFunction · 0.70

Calls

no outgoing calls

Tested by 4

mainFunction · 0.40
check_gradientFunction · 0.40
mainFunction · 0.40
test_roundtrip_on_layerFunction · 0.40