Skip to content

Commit d94d0ae

Browse files
committed
Remove dead code guess_n_parts function
1 parent 712c127 commit d94d0ae

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

llama.cpp

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -597,15 +597,6 @@ struct llama_model_loader {
597597
return false;
598598
}
599599

600-
uint32_t guess_n_parts() const {
601-
auto it = tensors_map.name_to_idx.find("tok_embeddings.weight");
602-
if (it == tensors_map.name_to_idx.end()) {
603-
throw std::runtime_error(std::string("missing tok_embeddings.weight"));
604-
}
605-
const llama_load_tensor & lt = tensors_map.tensors.at(it->second);
606-
return file_loader->hparams.n_embd / lt.ne.at(0);
607-
}
608-
609600
void calc_sizes(size_t * ctx_size_p, size_t * mmapped_size_p) const {
610601
*ctx_size_p = *mmapped_size_p = 0;
611602
for (const llama_load_tensor & lt : tensors_map.tensors) {

0 commit comments

Comments
 (0)