mirror of
https://github.com/LostRuins/koboldcpp.git
synced 2025-09-09 16:44:35 +00:00
allow customized rope to use model set values
This commit is contained in:
parent
f4ee91abbb
commit
8b919b5b57
4 changed files with 28 additions and 18 deletions
|
@ -290,14 +290,6 @@ void print_tok_vec(std::vector<float> &embd)
|
|||
}
|
||||
int filever = gguf_get_version(ctx);
|
||||
fileformatmeta->fileversion = filever;
|
||||
|
||||
//try to adapt if the rope_freq_base_train exceeds the auto one
|
||||
fkey = modelarch+".rope.freq_base";
|
||||
keyidx = gguf_find_key(ctx, fkey.c_str());
|
||||
if (keyidx != -1) {
|
||||
float fbt = gguf_get_val_f32(ctx, keyidx);
|
||||
fileformatmeta->freq_base_train = (fbt > 1.0f ? fbt : 0.0f);
|
||||
}
|
||||
}
|
||||
gguf_free(ctx);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue