Skip to content

Commit 7bbb5eb

Browse files
authored
base type on n_ff_exp instead
1 parent 8c41736 commit 7bbb5eb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/llama-model.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1100,8 +1100,9 @@ void llama_model::load_hparams(llama_model_loader & ml) {
11001100
ml.get_key(LLM_KV_EXPERT_SHARED_COUNT, hparams.n_expert_shared);
11011101
ml.get_key(LLM_KV_EXPERT_WEIGHTS_SCALE, hparams.expert_weights_scale);
11021102

1103-
switch (hparams.n_layer) {
1104-
case 28: type = LLM_TYPE_16B; break;
1103+
switch (hparams.n_ff_exp) {
1104+
case 1408: type = LLM_TYPE_16B; break;
1105+
case 1792: type = LLM_TYPE_20B; break;
11051106
default: type = LLM_TYPE_UNKNOWN;
11061107
}
11071108
} break;

0 commit comments

Comments
 (0)