File tree Expand file tree Collapse file tree 2 files changed +10
-11
lines changed Expand file tree Collapse file tree 2 files changed +10
-11
lines changed Original file line number Diff line number Diff line change @@ -170,10 +170,10 @@ struct llama_hparams {
170170 uint32_t n_embd_altup = 256 ;
171171
172172 // needed for sentence-transformers dense layers
173- uint32_t dense_2_feat_in = 0 ; // in_features of the 2_Dense
174- uint32_t dense_2_feat_out = 0 ; // out_features of the 2_Dense
175- uint32_t dense_3_feat_in = 0 ; // in_features of the 3_Dense
176- uint32_t dense_3_feat_out = 0 ; // out_features of the 3_Dense
173+ uint32_t dense_2_feat_in = 0 ; // in_features of the 2_Dense
174+ uint32_t dense_2_feat_out = 0 ; // out_features of the 2_Dense
175+ uint32_t dense_3_feat_in = 0 ; // in_features of the 3_Dense
176+ uint32_t dense_3_feat_out = 0 ; // out_features of the 3_Dense
177177
178178 // whether pooling_type can be overridden by user
179179 bool pooling_type_opt = true ;
Original file line number Diff line number Diff line change @@ -1229,14 +1229,13 @@ void llama_model::load_hparams(llama_model_loader & ml) {
12291229 ml.get_key(LLM_KV_DENSE_3_FEAT_OUT, hparams.dense_3_feat_out, false);
12301230 ml.get_key(LLM_KV_POOLING_TYPE_OPT, hparams.pooling_type_opt, false);
12311231
1232-
12331232 switch (hparams.n_layer) {
1234- case 24: type = LLM_TYPE_0_3B; break;
1235- default: type = LLM_TYPE_UNKNOWN;
1236- }
1237- hparams.f_attention_scale = 1.0f / std::sqrt(float(hparams.n_embd_head_k));
1238- }
1239- break;
1233+ case 24: type = LLM_TYPE_0_3B; break;
1234+ default: type = LLM_TYPE_UNKNOWN;
1235+ }
1236+ hparams.f_attention_scale = 1.0f / std::sqrt(float(hparams.n_embd_head_k));
1237+
1238+ } break;
12401239 case LLM_ARCH_STARCODER2:
12411240 {
12421241 ml.get_key(LLM_KV_ATTENTION_LAYERNORM_EPS, hparams.f_norm_eps);
You can’t perform that action at this time.
0 commit comments