diff options
author | saood06 <saood05@gmail.com> | 2025-04-22 01:34:13 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-04-22 08:34:13 +0200 |
commit | cc398007238cbbb064609cbdc9bc4aab03c658d7 (patch) | |
tree | a414370696faa5ad8a89ac5aa7ec7cf2171a78a4 /gguf-py/gguf/tensor_mapping.py | |
parent | 93cd77b65501246603061c7ee2801a992e3c6312 (diff) |
Add support for bitnet2b_2501 model (#337)
* add support for bitnet2b_2501 model
* Fixes
* Support both model names
---------
Co-authored-by: potassiummmm <zhou.hansong@outlook.com>
Diffstat (limited to 'gguf-py/gguf/tensor_mapping.py')
-rw-r--r-- | gguf-py/gguf/tensor_mapping.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gguf-py/gguf/tensor_mapping.py b/gguf-py/gguf/tensor_mapping.py index e8725426..1dea6a82 100644 --- a/gguf-py/gguf/tensor_mapping.py +++ b/gguf-py/gguf/tensor_mapping.py @@ -131,6 +131,7 @@ class TensorNameMap: "model.layers.{bid}.self_attn.qkv_proj", # phi3 "encoder.layers.{bid}.self_attention.query_key_value", # chatglm "transformer.layers.{bid}.attn.qkv_proj", # openelm + "layers.{bid}.attention.wqkv", ), # Attention query @@ -464,10 +465,14 @@ class TensorNameMap: MODEL_TENSOR.ATTN_SUB_NORM: ( "model.layers.{bid}.self_attn.inner_attn_ln", # bitnet + "layers.{bid}.attention.attn_sub_norm", # bitnet + "model.layers.{bid}.self_attn.attn_sub_norm", ), MODEL_TENSOR.FFN_SUB_NORM: ( "model.layers.{bid}.mlp.ffn_layernorm", # bitnet + "layers.{bid}.feed_forward.ffn_sub_norm", # bitnet + "model.layers.{bid}.mlp.ffn_sub_norm", ), MODEL_TENSOR.DEC_ATTN_NORM: ( |