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

Function assert_shape_2d

common/train.cpp:190–194  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

188}
189
190void assert_shape_2d(struct ggml_tensor * tensor, int64_t ne0, int64_t ne1) {
191 GGML_ASSERT(tensor->n_dims == 2);
192 GGML_ASSERT(tensor->ne[0] == ne0);
193 GGML_ASSERT(tensor->ne[1] == ne1);
194}
195
196void assert_shape_3d(struct ggml_tensor * tensor, int64_t ne0, int64_t ne1, int64_t ne2) {
197 GGML_ASSERT(tensor->n_dims == 3);

Callers 4

forward_batchFunction · 0.85
llama_build_train_graphsFunction · 0.85
init_modelFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected