hparams : add SWA rope parameters (#12374)

ggml-ci
This commit is contained in:
Georgi Gerganov 2025-03-14 09:03:24 +02:00 committed by GitHub
parent 84d5475541
commit 081bee8c64
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 26 additions and 20 deletions

View file

@ -79,7 +79,9 @@ struct llama_hparams {
float rope_attn_factor = 1.0f;
float rope_freq_base_train;
float rope_freq_base_train_swa;
float rope_freq_scale_train;
float rope_freq_scale_train_swa;
uint32_t n_ctx_orig_yarn;
float rope_yarn_log_mul;
@ -135,7 +137,7 @@ struct llama_hparams {
// dimension of the recurrent state embeddings
uint32_t n_embd_v_s() const;
bool is_sliding(uint32_t il) const;
bool is_swa(uint32_t il) const;
};
static_assert(std::is_trivially_copyable<llama_hparams>::value, "llama_hparams must be trivially copyable");