Skip to content

Commit

Permalink
gguf-py, llama : whitespace formatting fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
sszymczy committed Jun 21, 2024
1 parent 8bd8993 commit 83a94fe
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
1 change: 0 additions & 1 deletion gguf-py/gguf/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -884,7 +884,6 @@ class MODEL_TENSOR(IntEnum):
MODEL_TENSOR.DEC_FFN_DOWN,
MODEL_TENSOR.DEC_FFN_UP,
MODEL_TENSOR.DEC_OUTPUT_NORM,

MODEL_TENSOR.ENC_ATTN_NORM,
MODEL_TENSOR.ENC_ATTN_Q,
MODEL_TENSOR.ENC_ATTN_K,
Expand Down
2 changes: 0 additions & 2 deletions gguf-py/gguf/tensor_mapping.py
Original file line number Diff line number Diff line change
Expand Up @@ -518,8 +518,6 @@ class TensorNameMap:
MODEL_TENSOR.ENC_OUTPUT_NORM: (
"encoder.final_layer_norm", # t5
),


}

# architecture-specific block mappings
Expand Down
12 changes: 6 additions & 6 deletions llama.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2414,8 +2414,8 @@ struct llama_vocab {
bool tokenizer_add_bos = false;
bool tokenizer_add_eos = false;
bool tokenizer_ignore_merges = false;
bool tokenizer_remove_extra_whitespaces = false;
bool tokenizer_escape_whitespaces = true;
bool tokenizer_remove_extra_whitespaces = false;
bool tokenizer_escape_whitespaces = true;
bool tokenizer_treat_whitespace_as_suffix = false;

uint32_t n_precompiled_charsmap = 0;
Expand Down Expand Up @@ -4840,8 +4840,8 @@ static void llm_load_hparams(
case 24:
switch (hparams.n_ff) {
case 4096: model.type = e_model::MODEL_770M; break;
case 16384: model.type = e_model::MODEL_3B; break;
case 65536: model.type = e_model::MODEL_11B; break;
case 16384: model.type = e_model::MODEL_3B; break;
case 65536: model.type = e_model::MODEL_11B; break;
default: model.type = e_model::MODEL_UNKNOWN;
} break;
default: model.type = e_model::MODEL_UNKNOWN;
Expand Down Expand Up @@ -7680,8 +7680,8 @@ struct llm_build_context {
lctx.inp_s_copy = nullptr;
lctx.inp_s_mask = nullptr;
lctx.inp_s_seq = nullptr;
lctx.inp_pos_bucket = nullptr;
lctx.inp_enc_output = nullptr;
lctx.inp_pos_bucket = nullptr;
lctx.inp_enc_output = nullptr;
lctx.inp_cross_KQ_mask = nullptr;
}

Expand Down

0 comments on commit 83a94fe

Please sign in to comment.