MCPcopy Create free account
hub / github.com/andrewkchan/deepseek.cpp / check_tensor

Function check_tensor

src/model.cpp:129–136  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

127}
128
129std::optional<QTensor> check_tensor(const Tensor* tensor, Quant weight_quant, std::array<int, 4> shape, const int debug_line) {
130 if (tensor == nullptr) {
131 std::cerr << "FATAL: missing tensor at line " << debug_line << std::endl;
132 assert(false);
133 return std::nullopt;
134 }
135 return QTensor::from_codec_tensor(*tensor, weight_quant, shape, debug_line);
136};
137
138const Tensor* get_tensor(const YALMData& yalm, const std::string& key) {
139 auto it = yalm.tensors.find(key);

Callers 4

BlockMethod · 0.85
BlockMHAMethod · 0.85
BlockMLAMethod · 0.85
ModelMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected