Upload folder using huggingface_hub
Browse files- .gitattributes +1 -0
- added_tokens.json +41 -0
- chat_template.jinja +7 -0
- config.json +73 -0
- configuration_midashenglm.py +80 -0
- generation_config.json +9 -0
- merges.txt +0 -0
- model-00001-of-00007.safetensors +3 -0
- model-00002-of-00007.safetensors +3 -0
- model-00003-of-00007.safetensors +3 -0
- model-00004-of-00007.safetensors +3 -0
- model-00005-of-00007.safetensors +3 -0
- model-00006-of-00007.safetensors +3 -0
- model-00007-of-00007.safetensors +3 -0
- model.safetensors.index.json +745 -0
- modeling_midashenglm.py +636 -0
- preprocessor_config.json +13 -0
- processing_midashenglm.py +277 -0
- processor_config.json +10 -0
- special_tokens_map.json +144 -0
- tokenizer.json +3 -0
- tokenizer_config.json +365 -0
- vocab.json +0 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
tokenizer.json filter=lfs diff=lfs merge=lfs -text
|
added_tokens.json
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"</tool_call>": 151658,
|
| 3 |
+
"<tool_call>": 151657,
|
| 4 |
+
"<|AUDIO|>": 151646,
|
| 5 |
+
"<|IMAGE|>": 151655,
|
| 6 |
+
"<|VIDEO|>": 151656,
|
| 7 |
+
"<|ar|>": 151679,
|
| 8 |
+
"<|audio_bos|>": 151647,
|
| 9 |
+
"<|audio_eos|>": 151648,
|
| 10 |
+
"<|box_end|>": 151649,
|
| 11 |
+
"<|de|>": 151667,
|
| 12 |
+
"<|endoftext|>": 151643,
|
| 13 |
+
"<|en|>": 151665,
|
| 14 |
+
"<|es|>": 151668,
|
| 15 |
+
"<|file_sep|>": 151664,
|
| 16 |
+
"<|fim_middle|>": 151660,
|
| 17 |
+
"<|fim_pad|>": 151662,
|
| 18 |
+
"<|fim_prefix|>": 151659,
|
| 19 |
+
"<|fim_suffix|>": 151661,
|
| 20 |
+
"<|fr|>": 151669,
|
| 21 |
+
"<|hi|>": 151670,
|
| 22 |
+
"<|id|>": 151676,
|
| 23 |
+
"<|im_end|>": 151645,
|
| 24 |
+
"<|im_start|>": 151644,
|
| 25 |
+
"<|it|>": 151678,
|
| 26 |
+
"<|jp|>": 151680,
|
| 27 |
+
"<|kr|>": 151666,
|
| 28 |
+
"<|nl|>": 151674,
|
| 29 |
+
"<|pt|>": 151675,
|
| 30 |
+
"<|quad_end|>": 151651,
|
| 31 |
+
"<|quad_start|>": 151650,
|
| 32 |
+
"<|repo_name|>": 151663,
|
| 33 |
+
"<|ru|>": 151677,
|
| 34 |
+
"<|th|>": 151672,
|
| 35 |
+
"<|uk|>": 151671,
|
| 36 |
+
"<|unknown|>": 151681,
|
| 37 |
+
"<|vision_bos|>": 151652,
|
| 38 |
+
"<|vision_eos|>": 151653,
|
| 39 |
+
"<|vision_pad|>": 151654,
|
| 40 |
+
"<|vi|>": 151673
|
| 41 |
+
}
|
chat_template.jinja
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{% set audio_count = namespace(value=0) %}{% set image_count = namespace(value=0) %}{% set video_count = namespace(value=0) %}{% for message in messages %}{% if loop.first and message['role'] != 'system' %}<|im_start|>system
|
| 2 |
+
You are a helpful assistant.<|im_end|>
|
| 3 |
+
{% endif %}<|im_start|>{{ message['role'] }}
|
| 4 |
+
{% if message['content'] is string %}{{ message['content'] }}<|im_end|>
|
| 5 |
+
{% else %}{% for content in message['content'] %}{% if content['type'] == 'image' or 'image' in content or 'image_url' in content %}{% set image_count.value = image_count.value + 1 %}{% if add_vision_id %}Picture {{ image_count.value }}: {% endif %}<|vision_bos|><|IMAGE|><|vision_eos|>{% elif content['type'] == 'audio' or 'audio' in content or 'audio_url' in content %}{% set audio_count.value = audio_count.value + 1 %}{% if add_audio_id %}Audio {{ audio_count.value }}: {% endif %}<|audio_bos|><|AUDIO|><|audio_eos|>{% elif content['type'] == 'video' or 'video' in content %}{% set video_count.value = video_count.value + 1 %}{% if add_vision_id %}Video {{ video_count.value }}: {% endif %}<|vision_bos|><|VIDEO|><|vision_eos|>{% elif 'text' in content %}{{ content['text'] }}{% endif %}{% endfor %}<|im_end|>
|
| 6 |
+
{% endif %}{% endfor %}{% if add_generation_prompt %}<|im_start|>assistant
|
| 7 |
+
{% endif %}
|
config.json
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"architectures": [
|
| 3 |
+
"MiDashengLMModel"
|
| 4 |
+
],
|
| 5 |
+
"audio_encoder_config": {
|
| 6 |
+
"attn_drop_rate": 0.0,
|
| 7 |
+
"center": true,
|
| 8 |
+
"depth": 32,
|
| 9 |
+
"drop_rate": 0.0,
|
| 10 |
+
"embed_dim": 1280,
|
| 11 |
+
"f_max": 8000.0,
|
| 12 |
+
"f_min": 0.0,
|
| 13 |
+
"hop_length": 160,
|
| 14 |
+
"init_values": null,
|
| 15 |
+
"input_channels": 1,
|
| 16 |
+
"mlp_ratio": 4.0,
|
| 17 |
+
"model_type": "midashenglm_dasheng_encoder",
|
| 18 |
+
"n_fft": 512,
|
| 19 |
+
"n_mels": 64,
|
| 20 |
+
"num_heads": 16,
|
| 21 |
+
"outputdim": 527,
|
| 22 |
+
"patch_size": [
|
| 23 |
+
64,
|
| 24 |
+
4
|
| 25 |
+
],
|
| 26 |
+
"patch_stride": [
|
| 27 |
+
64,
|
| 28 |
+
4
|
| 29 |
+
],
|
| 30 |
+
"qkv_bias": true,
|
| 31 |
+
"sample_rate": 16000,
|
| 32 |
+
"target_length": 1008,
|
| 33 |
+
"win_length": 512
|
| 34 |
+
},
|
| 35 |
+
"audio_token_id": 151646,
|
| 36 |
+
"auto_map": {
|
| 37 |
+
"AutoConfig": "configuration_midashenglm.MiDashengLMConfig",
|
| 38 |
+
"AutoModelForCausalLM": "modeling_midashenglm.MiDashengLMModel"
|
| 39 |
+
},
|
| 40 |
+
"model_type": "midashenglm",
|
| 41 |
+
"subsample_factor": 5,
|
| 42 |
+
"text_config": {
|
| 43 |
+
"attention_dropout": 0.0,
|
| 44 |
+
"hidden_act": "silu",
|
| 45 |
+
"hidden_size": 3584,
|
| 46 |
+
"init_std": 0.02,
|
| 47 |
+
"initializer_range": 0.02,
|
| 48 |
+
"intermediate_size": 18944,
|
| 49 |
+
"max_position_embeddings": 32768,
|
| 50 |
+
"max_window_layers": 28,
|
| 51 |
+
"model_type": "qwen2_5_omni_text",
|
| 52 |
+
"num_attention_heads": 28,
|
| 53 |
+
"num_hidden_layers": 28,
|
| 54 |
+
"num_key_value_heads": 4,
|
| 55 |
+
"rms_norm_eps": 1e-06,
|
| 56 |
+
"rope_scaling": {
|
| 57 |
+
"mrope_section": [
|
| 58 |
+
16,
|
| 59 |
+
24,
|
| 60 |
+
24
|
| 61 |
+
],
|
| 62 |
+
"rope_type": "default",
|
| 63 |
+
"type": "default"
|
| 64 |
+
},
|
| 65 |
+
"rope_theta": 1000000.0,
|
| 66 |
+
"sliding_window": 32768,
|
| 67 |
+
"use_cache": true,
|
| 68 |
+
"use_sliding_window": false,
|
| 69 |
+
"vocab_size": 152064
|
| 70 |
+
},
|
| 71 |
+
"torch_dtype": "float32",
|
| 72 |
+
"transformers_version": "4.52.4"
|
| 73 |
+
}
|
configuration_midashenglm.py
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from typing import Dict, Optional, Tuple, Union
|
| 2 |
+
|
| 3 |
+
from transformers import PretrainedConfig
|
| 4 |
+
from transformers.models.qwen2_5_omni.configuration_qwen2_5_omni import (
|
| 5 |
+
Qwen2_5OmniTextConfig,
|
| 6 |
+
)
|
| 7 |
+
|
| 8 |
+
|
| 9 |
+
class DashengConfig(PretrainedConfig):
|
| 10 |
+
model_type = "midashenglm_dasheng_encoder"
|
| 11 |
+
|
| 12 |
+
def __init__(
|
| 13 |
+
self,
|
| 14 |
+
embed_dim: int = 768,
|
| 15 |
+
outputdim: int = 527,
|
| 16 |
+
patch_size: Union[int, Tuple[int, int]] = 16,
|
| 17 |
+
patch_stride: Union[int, Tuple[int, int]] = 16,
|
| 18 |
+
input_channels: int = 1,
|
| 19 |
+
target_length: int = 1012,
|
| 20 |
+
depth: int = 12,
|
| 21 |
+
num_heads: int = 12,
|
| 22 |
+
mlp_ratio: float = 4.0,
|
| 23 |
+
qkv_bias: bool = True,
|
| 24 |
+
init_values: Optional[float] = None,
|
| 25 |
+
drop_rate: float = 0.0,
|
| 26 |
+
attn_drop_rate: float = 0.0,
|
| 27 |
+
f_min: float = 0.0,
|
| 28 |
+
f_max: float = 8000.0,
|
| 29 |
+
center: bool = True,
|
| 30 |
+
win_length: int = 512,
|
| 31 |
+
hop_length: int = 160,
|
| 32 |
+
sample_rate: int = 16000,
|
| 33 |
+
n_fft: int = 512,
|
| 34 |
+
n_mels: int = 64,
|
| 35 |
+
**kwargs,
|
| 36 |
+
):
|
| 37 |
+
self.embed_dim = embed_dim
|
| 38 |
+
self.outputdim = outputdim
|
| 39 |
+
self.patch_size = patch_size
|
| 40 |
+
self.patch_stride = patch_stride
|
| 41 |
+
self.input_channels = input_channels
|
| 42 |
+
self.target_length = target_length
|
| 43 |
+
self.depth = depth
|
| 44 |
+
self.num_heads = num_heads
|
| 45 |
+
self.mlp_ratio = mlp_ratio
|
| 46 |
+
self.qkv_bias = qkv_bias
|
| 47 |
+
self.init_values = init_values
|
| 48 |
+
self.drop_rate = drop_rate
|
| 49 |
+
self.attn_drop_rate = attn_drop_rate
|
| 50 |
+
self.f_min = f_min
|
| 51 |
+
self.f_max = f_max
|
| 52 |
+
self.center = center
|
| 53 |
+
self.win_length = win_length
|
| 54 |
+
self.hop_length = hop_length
|
| 55 |
+
self.sample_rate = sample_rate
|
| 56 |
+
self.n_fft = n_fft
|
| 57 |
+
self.n_mels = n_mels
|
| 58 |
+
super().__init__(**kwargs)
|
| 59 |
+
|
| 60 |
+
|
| 61 |
+
class MiDashengLMConfig(PretrainedConfig):
|
| 62 |
+
model_type = "midashenglm"
|
| 63 |
+
|
| 64 |
+
def __init__(
|
| 65 |
+
self,
|
| 66 |
+
audio_encoder_config: Dict = {},
|
| 67 |
+
subsample_factor: int = 5,
|
| 68 |
+
text_config: Dict = {},
|
| 69 |
+
audio_token_id: Optional[int] = None,
|
| 70 |
+
**kwargs,
|
| 71 |
+
):
|
| 72 |
+
self.audio_encoder_config = DashengConfig(**audio_encoder_config)
|
| 73 |
+
self.subsample_factor = subsample_factor
|
| 74 |
+
self.text_config = (
|
| 75 |
+
Qwen2_5OmniTextConfig(**text_config)
|
| 76 |
+
if text_config
|
| 77 |
+
else Qwen2_5OmniTextConfig()
|
| 78 |
+
)
|
| 79 |
+
self.audio_token_id = audio_token_id
|
| 80 |
+
super().__init__(**kwargs)
|
generation_config.json
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"eos_token_id": [
|
| 3 |
+
151643,
|
| 4 |
+
151645
|
| 5 |
+
],
|
| 6 |
+
"max_length": 32768,
|
| 7 |
+
"pad_token_id": 151643,
|
| 8 |
+
"transformers_version": "4.52.4"
|
| 9 |
+
}
|
merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
model-00001-of-00007.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:311cd41867cd5db1cc101428e1b53cd483afe30ad69a6bbec5bd0668990e9b26
|
| 3 |
+
size 4961987424
|
model-00002-of-00007.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8b2c52f3b7959448572a59e4fafdf16bc1c7de466a0e0a84890daf0a7b27c72b
|
| 3 |
+
size 4932744424
|
model-00003-of-00007.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:88be6288965c59e15346294839b83b331d34e8c269697b9fe0e2a88561cb0ff5
|
| 3 |
+
size 4932744424
|
model-00004-of-00007.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:235e84a11a65c6232e53f99dbd357fa16840cfb9d0140f7f7d59d9cf21bff90b
|
| 3 |
+
size 4998852848
|
model-00005-of-00007.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:8ef7df2637fb95431d8ff71941d383d2c9d68353bebe9f6d07b69c1cc227b18d
|
| 3 |
+
size 4984124832
|
model-00006-of-00007.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:628a7b5342510640afbbd78492d1dd60c405fb561a504b47924cd2348a46f8cf
|
| 3 |
+
size 4932744480
|
model-00007-of-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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"metadata": {
|
| 3 |
+
"total_size": 33126960136
|
| 4 |
+
},
|
| 5 |
+
"weight_map": {
|
| 6 |
+
"audio_encoder.blocks.0.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 7 |
+
"audio_encoder.blocks.0.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 8 |
+
"audio_encoder.blocks.0.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 9 |
+
"audio_encoder.blocks.0.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 10 |
+
"audio_encoder.blocks.0.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 11 |
+
"audio_encoder.blocks.0.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 12 |
+
"audio_encoder.blocks.0.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 13 |
+
"audio_encoder.blocks.0.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 14 |
+
"audio_encoder.blocks.0.norm1.bias": "model-00001-of-00007.safetensors",
|
| 15 |
+
"audio_encoder.blocks.0.norm1.weight": "model-00001-of-00007.safetensors",
|
| 16 |
+
"audio_encoder.blocks.0.norm2.bias": "model-00001-of-00007.safetensors",
|
| 17 |
+
"audio_encoder.blocks.0.norm2.weight": "model-00001-of-00007.safetensors",
|
| 18 |
+
"audio_encoder.blocks.1.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 19 |
+
"audio_encoder.blocks.1.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 20 |
+
"audio_encoder.blocks.1.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 21 |
+
"audio_encoder.blocks.1.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 22 |
+
"audio_encoder.blocks.1.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 23 |
+
"audio_encoder.blocks.1.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 24 |
+
"audio_encoder.blocks.1.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 25 |
+
"audio_encoder.blocks.1.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 26 |
+
"audio_encoder.blocks.1.norm1.bias": "model-00001-of-00007.safetensors",
|
| 27 |
+
"audio_encoder.blocks.1.norm1.weight": "model-00001-of-00007.safetensors",
|
| 28 |
+
"audio_encoder.blocks.1.norm2.bias": "model-00001-of-00007.safetensors",
|
| 29 |
+
"audio_encoder.blocks.1.norm2.weight": "model-00001-of-00007.safetensors",
|
| 30 |
+
"audio_encoder.blocks.10.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 31 |
+
"audio_encoder.blocks.10.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 32 |
+
"audio_encoder.blocks.10.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 33 |
+
"audio_encoder.blocks.10.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 34 |
+
"audio_encoder.blocks.10.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 35 |
+
"audio_encoder.blocks.10.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 36 |
+
"audio_encoder.blocks.10.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 37 |
+
"audio_encoder.blocks.10.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 38 |
+
"audio_encoder.blocks.10.norm1.bias": "model-00001-of-00007.safetensors",
|
| 39 |
+
"audio_encoder.blocks.10.norm1.weight": "model-00001-of-00007.safetensors",
|
| 40 |
+
"audio_encoder.blocks.10.norm2.bias": "model-00001-of-00007.safetensors",
|
| 41 |
+
"audio_encoder.blocks.10.norm2.weight": "model-00001-of-00007.safetensors",
|
| 42 |
+
"audio_encoder.blocks.11.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 43 |
+
"audio_encoder.blocks.11.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 44 |
+
"audio_encoder.blocks.11.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 45 |
+
"audio_encoder.blocks.11.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 46 |
+
"audio_encoder.blocks.11.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 47 |
+
"audio_encoder.blocks.11.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 48 |
+
"audio_encoder.blocks.11.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 49 |
+
"audio_encoder.blocks.11.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 50 |
+
"audio_encoder.blocks.11.norm1.bias": "model-00001-of-00007.safetensors",
|
| 51 |
+
"audio_encoder.blocks.11.norm1.weight": "model-00001-of-00007.safetensors",
|
| 52 |
+
"audio_encoder.blocks.11.norm2.bias": "model-00001-of-00007.safetensors",
|
| 53 |
+
"audio_encoder.blocks.11.norm2.weight": "model-00001-of-00007.safetensors",
|
| 54 |
+
"audio_encoder.blocks.12.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 55 |
+
"audio_encoder.blocks.12.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 56 |
+
"audio_encoder.blocks.12.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 57 |
+
"audio_encoder.blocks.12.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 58 |
+
"audio_encoder.blocks.12.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 59 |
+
"audio_encoder.blocks.12.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 60 |
+
"audio_encoder.blocks.12.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 61 |
+
"audio_encoder.blocks.12.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 62 |
+
"audio_encoder.blocks.12.norm1.bias": "model-00001-of-00007.safetensors",
|
| 63 |
+
"audio_encoder.blocks.12.norm1.weight": "model-00001-of-00007.safetensors",
|
| 64 |
+
"audio_encoder.blocks.12.norm2.bias": "model-00001-of-00007.safetensors",
|
| 65 |
+
"audio_encoder.blocks.12.norm2.weight": "model-00001-of-00007.safetensors",
|
| 66 |
+
"audio_encoder.blocks.13.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 67 |
+
"audio_encoder.blocks.13.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 68 |
+
"audio_encoder.blocks.13.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 69 |
+
"audio_encoder.blocks.13.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 70 |
+
"audio_encoder.blocks.13.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 71 |
+
"audio_encoder.blocks.13.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 72 |
+
"audio_encoder.blocks.13.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 73 |
+
"audio_encoder.blocks.13.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 74 |
+
"audio_encoder.blocks.13.norm1.bias": "model-00001-of-00007.safetensors",
|
| 75 |
+
"audio_encoder.blocks.13.norm1.weight": "model-00001-of-00007.safetensors",
|
| 76 |
+
"audio_encoder.blocks.13.norm2.bias": "model-00001-of-00007.safetensors",
|
| 77 |
+
"audio_encoder.blocks.13.norm2.weight": "model-00001-of-00007.safetensors",
|
| 78 |
+
"audio_encoder.blocks.14.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 79 |
+
"audio_encoder.blocks.14.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 80 |
+
"audio_encoder.blocks.14.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 81 |
+
"audio_encoder.blocks.14.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 82 |
+
"audio_encoder.blocks.14.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 83 |
+
"audio_encoder.blocks.14.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 84 |
+
"audio_encoder.blocks.14.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 85 |
+
"audio_encoder.blocks.14.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 86 |
+
"audio_encoder.blocks.14.norm1.bias": "model-00001-of-00007.safetensors",
|
| 87 |
+
"audio_encoder.blocks.14.norm1.weight": "model-00001-of-00007.safetensors",
|
| 88 |
+
"audio_encoder.blocks.14.norm2.bias": "model-00001-of-00007.safetensors",
|
| 89 |
+
"audio_encoder.blocks.14.norm2.weight": "model-00001-of-00007.safetensors",
|
| 90 |
+
"audio_encoder.blocks.15.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 91 |
+
"audio_encoder.blocks.15.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 92 |
+
"audio_encoder.blocks.15.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 93 |
+
"audio_encoder.blocks.15.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 94 |
+
"audio_encoder.blocks.15.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 95 |
+
"audio_encoder.blocks.15.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 96 |
+
"audio_encoder.blocks.15.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 97 |
+
"audio_encoder.blocks.15.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 98 |
+
"audio_encoder.blocks.15.norm1.bias": "model-00001-of-00007.safetensors",
|
| 99 |
+
"audio_encoder.blocks.15.norm1.weight": "model-00001-of-00007.safetensors",
|
| 100 |
+
"audio_encoder.blocks.15.norm2.bias": "model-00001-of-00007.safetensors",
|
| 101 |
+
"audio_encoder.blocks.15.norm2.weight": "model-00001-of-00007.safetensors",
|
| 102 |
+
"audio_encoder.blocks.16.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 103 |
+
"audio_encoder.blocks.16.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 104 |
+
"audio_encoder.blocks.16.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 105 |
+
"audio_encoder.blocks.16.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 106 |
+
"audio_encoder.blocks.16.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 107 |
+
"audio_encoder.blocks.16.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 108 |
+
"audio_encoder.blocks.16.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 109 |
+
"audio_encoder.blocks.16.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 110 |
+
"audio_encoder.blocks.16.norm1.bias": "model-00001-of-00007.safetensors",
|
| 111 |
+
"audio_encoder.blocks.16.norm1.weight": "model-00001-of-00007.safetensors",
|
| 112 |
+
"audio_encoder.blocks.16.norm2.bias": "model-00001-of-00007.safetensors",
|
| 113 |
+
"audio_encoder.blocks.16.norm2.weight": "model-00001-of-00007.safetensors",
|
| 114 |
+
"audio_encoder.blocks.17.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 115 |
+
"audio_encoder.blocks.17.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 116 |
+
"audio_encoder.blocks.17.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 117 |
+
"audio_encoder.blocks.17.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 118 |
+
"audio_encoder.blocks.17.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 119 |
+
"audio_encoder.blocks.17.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 120 |
+
"audio_encoder.blocks.17.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 121 |
+
"audio_encoder.blocks.17.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 122 |
+
"audio_encoder.blocks.17.norm1.bias": "model-00001-of-00007.safetensors",
|
| 123 |
+
"audio_encoder.blocks.17.norm1.weight": "model-00001-of-00007.safetensors",
|
| 124 |
+
"audio_encoder.blocks.17.norm2.bias": "model-00001-of-00007.safetensors",
|
| 125 |
+
"audio_encoder.blocks.17.norm2.weight": "model-00001-of-00007.safetensors",
|
| 126 |
+
"audio_encoder.blocks.18.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 127 |
+
"audio_encoder.blocks.18.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 128 |
+
"audio_encoder.blocks.18.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 129 |
+
"audio_encoder.blocks.18.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 130 |
+
"audio_encoder.blocks.18.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 131 |
+
"audio_encoder.blocks.18.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 132 |
+
"audio_encoder.blocks.18.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 133 |
+
"audio_encoder.blocks.18.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 134 |
+
"audio_encoder.blocks.18.norm1.bias": "model-00001-of-00007.safetensors",
|
| 135 |
+
"audio_encoder.blocks.18.norm1.weight": "model-00001-of-00007.safetensors",
|
| 136 |
+
"audio_encoder.blocks.18.norm2.bias": "model-00001-of-00007.safetensors",
|
| 137 |
+
"audio_encoder.blocks.18.norm2.weight": "model-00001-of-00007.safetensors",
|
| 138 |
+
"audio_encoder.blocks.19.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 139 |
+
"audio_encoder.blocks.19.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 140 |
+
"audio_encoder.blocks.19.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 141 |
+
"audio_encoder.blocks.19.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 142 |
+
"audio_encoder.blocks.19.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 143 |
+
"audio_encoder.blocks.19.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 144 |
+
"audio_encoder.blocks.19.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 145 |
+
"audio_encoder.blocks.19.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 146 |
+
"audio_encoder.blocks.19.norm1.bias": "model-00001-of-00007.safetensors",
|
| 147 |
+
"audio_encoder.blocks.19.norm1.weight": "model-00001-of-00007.safetensors",
|
| 148 |
+
"audio_encoder.blocks.19.norm2.bias": "model-00001-of-00007.safetensors",
|
| 149 |
+
"audio_encoder.blocks.19.norm2.weight": "model-00001-of-00007.safetensors",
|
| 150 |
+
"audio_encoder.blocks.2.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 151 |
+
"audio_encoder.blocks.2.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 152 |
+
"audio_encoder.blocks.2.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 153 |
+
"audio_encoder.blocks.2.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 154 |
+
"audio_encoder.blocks.2.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 155 |
+
"audio_encoder.blocks.2.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 156 |
+
"audio_encoder.blocks.2.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 157 |
+
"audio_encoder.blocks.2.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 158 |
+
"audio_encoder.blocks.2.norm1.bias": "model-00001-of-00007.safetensors",
|
| 159 |
+
"audio_encoder.blocks.2.norm1.weight": "model-00001-of-00007.safetensors",
|
| 160 |
+
"audio_encoder.blocks.2.norm2.bias": "model-00001-of-00007.safetensors",
|
| 161 |
+
"audio_encoder.blocks.2.norm2.weight": "model-00001-of-00007.safetensors",
|
| 162 |
+
"audio_encoder.blocks.20.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 163 |
+
"audio_encoder.blocks.20.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 164 |
+
"audio_encoder.blocks.20.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 165 |
+
"audio_encoder.blocks.20.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 166 |
+
"audio_encoder.blocks.20.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 167 |
+
"audio_encoder.blocks.20.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 168 |
+
"audio_encoder.blocks.20.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 169 |
+
"audio_encoder.blocks.20.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 170 |
+
"audio_encoder.blocks.20.norm1.bias": "model-00001-of-00007.safetensors",
|
| 171 |
+
"audio_encoder.blocks.20.norm1.weight": "model-00001-of-00007.safetensors",
|
| 172 |
+
"audio_encoder.blocks.20.norm2.bias": "model-00001-of-00007.safetensors",
|
| 173 |
+
"audio_encoder.blocks.20.norm2.weight": "model-00001-of-00007.safetensors",
|
| 174 |
+
"audio_encoder.blocks.21.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 175 |
+
"audio_encoder.blocks.21.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 176 |
+
"audio_encoder.blocks.21.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 177 |
+
"audio_encoder.blocks.21.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 178 |
+
"audio_encoder.blocks.21.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 179 |
+
"audio_encoder.blocks.21.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 180 |
+
"audio_encoder.blocks.21.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 181 |
+
"audio_encoder.blocks.21.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 182 |
+
"audio_encoder.blocks.21.norm1.bias": "model-00001-of-00007.safetensors",
|
| 183 |
+
"audio_encoder.blocks.21.norm1.weight": "model-00001-of-00007.safetensors",
|
| 184 |
+
"audio_encoder.blocks.21.norm2.bias": "model-00001-of-00007.safetensors",
|
| 185 |
+
"audio_encoder.blocks.21.norm2.weight": "model-00001-of-00007.safetensors",
|
| 186 |
+
"audio_encoder.blocks.22.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 187 |
+
"audio_encoder.blocks.22.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 188 |
+
"audio_encoder.blocks.22.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 189 |
+
"audio_encoder.blocks.22.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 190 |
+
"audio_encoder.blocks.22.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 191 |
+
"audio_encoder.blocks.22.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 192 |
+
"audio_encoder.blocks.22.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 193 |
+
"audio_encoder.blocks.22.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 194 |
+
"audio_encoder.blocks.22.norm1.bias": "model-00001-of-00007.safetensors",
|
| 195 |
+
"audio_encoder.blocks.22.norm1.weight": "model-00001-of-00007.safetensors",
|
| 196 |
+
"audio_encoder.blocks.22.norm2.bias": "model-00001-of-00007.safetensors",
|
| 197 |
+
"audio_encoder.blocks.22.norm2.weight": "model-00001-of-00007.safetensors",
|
| 198 |
+
"audio_encoder.blocks.23.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 199 |
+
"audio_encoder.blocks.23.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 200 |
+
"audio_encoder.blocks.23.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 201 |
+
"audio_encoder.blocks.23.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 202 |
+
"audio_encoder.blocks.23.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 203 |
+
"audio_encoder.blocks.23.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 204 |
+
"audio_encoder.blocks.23.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 205 |
+
"audio_encoder.blocks.23.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 206 |
+
"audio_encoder.blocks.23.norm1.bias": "model-00001-of-00007.safetensors",
|
| 207 |
+
"audio_encoder.blocks.23.norm1.weight": "model-00001-of-00007.safetensors",
|
| 208 |
+
"audio_encoder.blocks.23.norm2.bias": "model-00001-of-00007.safetensors",
|
| 209 |
+
"audio_encoder.blocks.23.norm2.weight": "model-00001-of-00007.safetensors",
|
| 210 |
+
"audio_encoder.blocks.24.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 211 |
+
"audio_encoder.blocks.24.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 212 |
+
"audio_encoder.blocks.24.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 213 |
+
"audio_encoder.blocks.24.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 214 |
+
"audio_encoder.blocks.24.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 215 |
+
"audio_encoder.blocks.24.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 216 |
+
"audio_encoder.blocks.24.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 217 |
+
"audio_encoder.blocks.24.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 218 |
+
"audio_encoder.blocks.24.norm1.bias": "model-00001-of-00007.safetensors",
|
| 219 |
+
"audio_encoder.blocks.24.norm1.weight": "model-00001-of-00007.safetensors",
|
| 220 |
+
"audio_encoder.blocks.24.norm2.bias": "model-00001-of-00007.safetensors",
|
| 221 |
+
"audio_encoder.blocks.24.norm2.weight": "model-00001-of-00007.safetensors",
|
| 222 |
+
"audio_encoder.blocks.25.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 223 |
+
"audio_encoder.blocks.25.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 224 |
+
"audio_encoder.blocks.25.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 225 |
+
"audio_encoder.blocks.25.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 226 |
+
"audio_encoder.blocks.25.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 227 |
+
"audio_encoder.blocks.25.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 228 |
+
"audio_encoder.blocks.25.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 229 |
+
"audio_encoder.blocks.25.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 230 |
+
"audio_encoder.blocks.25.norm1.bias": "model-00001-of-00007.safetensors",
|
| 231 |
+
"audio_encoder.blocks.25.norm1.weight": "model-00001-of-00007.safetensors",
|
| 232 |
+
"audio_encoder.blocks.25.norm2.bias": "model-00001-of-00007.safetensors",
|
| 233 |
+
"audio_encoder.blocks.25.norm2.weight": "model-00001-of-00007.safetensors",
|
| 234 |
+
"audio_encoder.blocks.26.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 235 |
+
"audio_encoder.blocks.26.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 236 |
+
"audio_encoder.blocks.26.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 237 |
+
"audio_encoder.blocks.26.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 238 |
+
"audio_encoder.blocks.26.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 239 |
+
"audio_encoder.blocks.26.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 240 |
+
"audio_encoder.blocks.26.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 241 |
+
"audio_encoder.blocks.26.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 242 |
+
"audio_encoder.blocks.26.norm1.bias": "model-00001-of-00007.safetensors",
|
| 243 |
+
"audio_encoder.blocks.26.norm1.weight": "model-00001-of-00007.safetensors",
|
| 244 |
+
"audio_encoder.blocks.26.norm2.bias": "model-00001-of-00007.safetensors",
|
| 245 |
+
"audio_encoder.blocks.26.norm2.weight": "model-00001-of-00007.safetensors",
|
| 246 |
+
"audio_encoder.blocks.27.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 247 |
+
"audio_encoder.blocks.27.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 248 |
+
"audio_encoder.blocks.27.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 249 |
+
"audio_encoder.blocks.27.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 250 |
+
"audio_encoder.blocks.27.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 251 |
+
"audio_encoder.blocks.27.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 252 |
+
"audio_encoder.blocks.27.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 253 |
+
"audio_encoder.blocks.27.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 254 |
+
"audio_encoder.blocks.27.norm1.bias": "model-00001-of-00007.safetensors",
|
| 255 |
+
"audio_encoder.blocks.27.norm1.weight": "model-00001-of-00007.safetensors",
|
| 256 |
+
"audio_encoder.blocks.27.norm2.bias": "model-00001-of-00007.safetensors",
|
| 257 |
+
"audio_encoder.blocks.27.norm2.weight": "model-00001-of-00007.safetensors",
|
| 258 |
+
"audio_encoder.blocks.28.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 259 |
+
"audio_encoder.blocks.28.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 260 |
+
"audio_encoder.blocks.28.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 261 |
+
"audio_encoder.blocks.28.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 262 |
+
"audio_encoder.blocks.28.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 263 |
+
"audio_encoder.blocks.28.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 264 |
+
"audio_encoder.blocks.28.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 265 |
+
"audio_encoder.blocks.28.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 266 |
+
"audio_encoder.blocks.28.norm1.bias": "model-00001-of-00007.safetensors",
|
| 267 |
+
"audio_encoder.blocks.28.norm1.weight": "model-00001-of-00007.safetensors",
|
| 268 |
+
"audio_encoder.blocks.28.norm2.bias": "model-00001-of-00007.safetensors",
|
| 269 |
+
"audio_encoder.blocks.28.norm2.weight": "model-00001-of-00007.safetensors",
|
| 270 |
+
"audio_encoder.blocks.29.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 271 |
+
"audio_encoder.blocks.29.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 272 |
+
"audio_encoder.blocks.29.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 273 |
+
"audio_encoder.blocks.29.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 274 |
+
"audio_encoder.blocks.29.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 275 |
+
"audio_encoder.blocks.29.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 276 |
+
"audio_encoder.blocks.29.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 277 |
+
"audio_encoder.blocks.29.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 278 |
+
"audio_encoder.blocks.29.norm1.bias": "model-00001-of-00007.safetensors",
|
| 279 |
+
"audio_encoder.blocks.29.norm1.weight": "model-00001-of-00007.safetensors",
|
| 280 |
+
"audio_encoder.blocks.29.norm2.bias": "model-00001-of-00007.safetensors",
|
| 281 |
+
"audio_encoder.blocks.29.norm2.weight": "model-00001-of-00007.safetensors",
|
| 282 |
+
"audio_encoder.blocks.3.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 283 |
+
"audio_encoder.blocks.3.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 284 |
+
"audio_encoder.blocks.3.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 285 |
+
"audio_encoder.blocks.3.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 286 |
+
"audio_encoder.blocks.3.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 287 |
+
"audio_encoder.blocks.3.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 288 |
+
"audio_encoder.blocks.3.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 289 |
+
"audio_encoder.blocks.3.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 290 |
+
"audio_encoder.blocks.3.norm1.bias": "model-00001-of-00007.safetensors",
|
| 291 |
+
"audio_encoder.blocks.3.norm1.weight": "model-00001-of-00007.safetensors",
|
| 292 |
+
"audio_encoder.blocks.3.norm2.bias": "model-00001-of-00007.safetensors",
|
| 293 |
+
"audio_encoder.blocks.3.norm2.weight": "model-00001-of-00007.safetensors",
|
| 294 |
+
"audio_encoder.blocks.30.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 295 |
+
"audio_encoder.blocks.30.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 296 |
+
"audio_encoder.blocks.30.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 297 |
+
"audio_encoder.blocks.30.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 298 |
+
"audio_encoder.blocks.30.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 299 |
+
"audio_encoder.blocks.30.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 300 |
+
"audio_encoder.blocks.30.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 301 |
+
"audio_encoder.blocks.30.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 302 |
+
"audio_encoder.blocks.30.norm1.bias": "model-00001-of-00007.safetensors",
|
| 303 |
+
"audio_encoder.blocks.30.norm1.weight": "model-00001-of-00007.safetensors",
|
| 304 |
+
"audio_encoder.blocks.30.norm2.bias": "model-00001-of-00007.safetensors",
|
| 305 |
+
"audio_encoder.blocks.30.norm2.weight": "model-00001-of-00007.safetensors",
|
| 306 |
+
"audio_encoder.blocks.31.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 307 |
+
"audio_encoder.blocks.31.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 308 |
+
"audio_encoder.blocks.31.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 309 |
+
"audio_encoder.blocks.31.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 310 |
+
"audio_encoder.blocks.31.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 311 |
+
"audio_encoder.blocks.31.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 312 |
+
"audio_encoder.blocks.31.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 313 |
+
"audio_encoder.blocks.31.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 314 |
+
"audio_encoder.blocks.31.norm1.bias": "model-00001-of-00007.safetensors",
|
| 315 |
+
"audio_encoder.blocks.31.norm1.weight": "model-00001-of-00007.safetensors",
|
| 316 |
+
"audio_encoder.blocks.31.norm2.bias": "model-00001-of-00007.safetensors",
|
| 317 |
+
"audio_encoder.blocks.31.norm2.weight": "model-00001-of-00007.safetensors",
|
| 318 |
+
"audio_encoder.blocks.4.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 319 |
+
"audio_encoder.blocks.4.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 320 |
+
"audio_encoder.blocks.4.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 321 |
+
"audio_encoder.blocks.4.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 322 |
+
"audio_encoder.blocks.4.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 323 |
+
"audio_encoder.blocks.4.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 324 |
+
"audio_encoder.blocks.4.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 325 |
+
"audio_encoder.blocks.4.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 326 |
+
"audio_encoder.blocks.4.norm1.bias": "model-00001-of-00007.safetensors",
|
| 327 |
+
"audio_encoder.blocks.4.norm1.weight": "model-00001-of-00007.safetensors",
|
| 328 |
+
"audio_encoder.blocks.4.norm2.bias": "model-00001-of-00007.safetensors",
|
| 329 |
+
"audio_encoder.blocks.4.norm2.weight": "model-00001-of-00007.safetensors",
|
| 330 |
+
"audio_encoder.blocks.5.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 331 |
+
"audio_encoder.blocks.5.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 332 |
+
"audio_encoder.blocks.5.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 333 |
+
"audio_encoder.blocks.5.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 334 |
+
"audio_encoder.blocks.5.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 335 |
+
"audio_encoder.blocks.5.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 336 |
+
"audio_encoder.blocks.5.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 337 |
+
"audio_encoder.blocks.5.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 338 |
+
"audio_encoder.blocks.5.norm1.bias": "model-00001-of-00007.safetensors",
|
| 339 |
+
"audio_encoder.blocks.5.norm1.weight": "model-00001-of-00007.safetensors",
|
| 340 |
+
"audio_encoder.blocks.5.norm2.bias": "model-00001-of-00007.safetensors",
|
| 341 |
+
"audio_encoder.blocks.5.norm2.weight": "model-00001-of-00007.safetensors",
|
| 342 |
+
"audio_encoder.blocks.6.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 343 |
+
"audio_encoder.blocks.6.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 344 |
+
"audio_encoder.blocks.6.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 345 |
+
"audio_encoder.blocks.6.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 346 |
+
"audio_encoder.blocks.6.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 347 |
+
"audio_encoder.blocks.6.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 348 |
+
"audio_encoder.blocks.6.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 349 |
+
"audio_encoder.blocks.6.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 350 |
+
"audio_encoder.blocks.6.norm1.bias": "model-00001-of-00007.safetensors",
|
| 351 |
+
"audio_encoder.blocks.6.norm1.weight": "model-00001-of-00007.safetensors",
|
| 352 |
+
"audio_encoder.blocks.6.norm2.bias": "model-00001-of-00007.safetensors",
|
| 353 |
+
"audio_encoder.blocks.6.norm2.weight": "model-00001-of-00007.safetensors",
|
| 354 |
+
"audio_encoder.blocks.7.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 355 |
+
"audio_encoder.blocks.7.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 356 |
+
"audio_encoder.blocks.7.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 357 |
+
"audio_encoder.blocks.7.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 358 |
+
"audio_encoder.blocks.7.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 359 |
+
"audio_encoder.blocks.7.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 360 |
+
"audio_encoder.blocks.7.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 361 |
+
"audio_encoder.blocks.7.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 362 |
+
"audio_encoder.blocks.7.norm1.bias": "model-00001-of-00007.safetensors",
|
| 363 |
+
"audio_encoder.blocks.7.norm1.weight": "model-00001-of-00007.safetensors",
|
| 364 |
+
"audio_encoder.blocks.7.norm2.bias": "model-00001-of-00007.safetensors",
|
| 365 |
+
"audio_encoder.blocks.7.norm2.weight": "model-00001-of-00007.safetensors",
|
| 366 |
+
"audio_encoder.blocks.8.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 367 |
+
"audio_encoder.blocks.8.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 368 |
+
"audio_encoder.blocks.8.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 369 |
+
"audio_encoder.blocks.8.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 370 |
+
"audio_encoder.blocks.8.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 371 |
+
"audio_encoder.blocks.8.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 372 |
+
"audio_encoder.blocks.8.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 373 |
+
"audio_encoder.blocks.8.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 374 |
+
"audio_encoder.blocks.8.norm1.bias": "model-00001-of-00007.safetensors",
|
| 375 |
+
"audio_encoder.blocks.8.norm1.weight": "model-00001-of-00007.safetensors",
|
| 376 |
+
"audio_encoder.blocks.8.norm2.bias": "model-00001-of-00007.safetensors",
|
| 377 |
+
"audio_encoder.blocks.8.norm2.weight": "model-00001-of-00007.safetensors",
|
| 378 |
+
"audio_encoder.blocks.9.attn.proj.bias": "model-00001-of-00007.safetensors",
|
| 379 |
+
"audio_encoder.blocks.9.attn.proj.weight": "model-00001-of-00007.safetensors",
|
| 380 |
+
"audio_encoder.blocks.9.attn.qkv.bias": "model-00001-of-00007.safetensors",
|
| 381 |
+
"audio_encoder.blocks.9.attn.qkv.weight": "model-00001-of-00007.safetensors",
|
| 382 |
+
"audio_encoder.blocks.9.mlp.fc1.bias": "model-00001-of-00007.safetensors",
|
| 383 |
+
"audio_encoder.blocks.9.mlp.fc1.weight": "model-00001-of-00007.safetensors",
|
| 384 |
+
"audio_encoder.blocks.9.mlp.fc2.bias": "model-00001-of-00007.safetensors",
|
| 385 |
+
"audio_encoder.blocks.9.mlp.fc2.weight": "model-00001-of-00007.safetensors",
|
| 386 |
+
"audio_encoder.blocks.9.norm1.bias": "model-00001-of-00007.safetensors",
|
| 387 |
+
"audio_encoder.blocks.9.norm1.weight": "model-00001-of-00007.safetensors",
|
| 388 |
+
"audio_encoder.blocks.9.norm2.bias": "model-00001-of-00007.safetensors",
|
| 389 |
+
"audio_encoder.blocks.9.norm2.weight": "model-00001-of-00007.safetensors",
|
| 390 |
+
"audio_encoder.freq_pos_embed": "model-00001-of-00007.safetensors",
|
| 391 |
+
"audio_encoder.init_bn.bias": "model-00001-of-00007.safetensors",
|
| 392 |
+
"audio_encoder.init_bn.num_batches_tracked": "model-00001-of-00007.safetensors",
|
| 393 |
+
"audio_encoder.init_bn.running_mean": "model-00001-of-00007.safetensors",
|
| 394 |
+
"audio_encoder.init_bn.running_var": "model-00001-of-00007.safetensors",
|
| 395 |
+
"audio_encoder.init_bn.weight": "model-00001-of-00007.safetensors",
|
| 396 |
+
"audio_encoder.norm.bias": "model-00001-of-00007.safetensors",
|
| 397 |
+
"audio_encoder.norm.weight": "model-00001-of-00007.safetensors",
|
| 398 |
+
"audio_encoder.patch_embed.proj.bias": "model-00001-of-00007.safetensors",
|
| 399 |
+
"audio_encoder.patch_embed.proj.weight": "model-00001-of-00007.safetensors",
|
| 400 |
+
"audio_encoder.time_pos_embed": "model-00001-of-00007.safetensors",
|
| 401 |
+
"audio_projector.net.0.bias": "model-00001-of-00007.safetensors",
|
| 402 |
+
"audio_projector.net.0.weight": "model-00001-of-00007.safetensors",
|
| 403 |
+
"audio_projector.net.2.bias": "model-00001-of-00007.safetensors",
|
| 404 |
+
"audio_projector.net.2.weight": "model-00001-of-00007.safetensors",
|
| 405 |
+
"decoder.lm_head.weight": "model-00007-of-00007.safetensors",
|
| 406 |
+
"decoder.model.embed_tokens.weight": "model-00001-of-00007.safetensors",
|
| 407 |
+
"decoder.model.layers.0.input_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 408 |
+
"decoder.model.layers.0.mlp.down_proj.weight": "model-00002-of-00007.safetensors",
|
| 409 |
+
"decoder.model.layers.0.mlp.gate_proj.weight": "model-00002-of-00007.safetensors",
|
| 410 |
+
"decoder.model.layers.0.mlp.up_proj.weight": "model-00002-of-00007.safetensors",
|
| 411 |
+
"decoder.model.layers.0.post_attention_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 412 |
+
"decoder.model.layers.0.self_attn.k_proj.bias": "model-00001-of-00007.safetensors",
|
| 413 |
+
"decoder.model.layers.0.self_attn.k_proj.weight": "model-00001-of-00007.safetensors",
|
| 414 |
+
"decoder.model.layers.0.self_attn.o_proj.weight": "model-00001-of-00007.safetensors",
|
| 415 |
+
"decoder.model.layers.0.self_attn.q_proj.bias": "model-00001-of-00007.safetensors",
|
| 416 |
+
"decoder.model.layers.0.self_attn.q_proj.weight": "model-00001-of-00007.safetensors",
|
| 417 |
+
"decoder.model.layers.0.self_attn.v_proj.bias": "model-00001-of-00007.safetensors",
|
| 418 |
+
"decoder.model.layers.0.self_attn.v_proj.weight": "model-00001-of-00007.safetensors",
|
| 419 |
+
"decoder.model.layers.1.input_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 420 |
+
"decoder.model.layers.1.mlp.down_proj.weight": "model-00002-of-00007.safetensors",
|
| 421 |
+
"decoder.model.layers.1.mlp.gate_proj.weight": "model-00002-of-00007.safetensors",
|
| 422 |
+
"decoder.model.layers.1.mlp.up_proj.weight": "model-00002-of-00007.safetensors",
|
| 423 |
+
"decoder.model.layers.1.post_attention_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 424 |
+
"decoder.model.layers.1.self_attn.k_proj.bias": "model-00002-of-00007.safetensors",
|
| 425 |
+
"decoder.model.layers.1.self_attn.k_proj.weight": "model-00002-of-00007.safetensors",
|
| 426 |
+
"decoder.model.layers.1.self_attn.o_proj.weight": "model-00002-of-00007.safetensors",
|
| 427 |
+
"decoder.model.layers.1.self_attn.q_proj.bias": "model-00002-of-00007.safetensors",
|
| 428 |
+
"decoder.model.layers.1.self_attn.q_proj.weight": "model-00002-of-00007.safetensors",
|
| 429 |
+
"decoder.model.layers.1.self_attn.v_proj.bias": "model-00002-of-00007.safetensors",
|
| 430 |
+
"decoder.model.layers.1.self_attn.v_proj.weight": "model-00002-of-00007.safetensors",
|
| 431 |
+
"decoder.model.layers.10.input_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 432 |
+
"decoder.model.layers.10.mlp.down_proj.weight": "model-00004-of-00007.safetensors",
|
| 433 |
+
"decoder.model.layers.10.mlp.gate_proj.weight": "model-00003-of-00007.safetensors",
|
| 434 |
+
"decoder.model.layers.10.mlp.up_proj.weight": "model-00003-of-00007.safetensors",
|
| 435 |
+
"decoder.model.layers.10.post_attention_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 436 |
+
"decoder.model.layers.10.self_attn.k_proj.bias": "model-00003-of-00007.safetensors",
|
| 437 |
+
"decoder.model.layers.10.self_attn.k_proj.weight": "model-00003-of-00007.safetensors",
|
| 438 |
+
"decoder.model.layers.10.self_attn.o_proj.weight": "model-00003-of-00007.safetensors",
|
| 439 |
+
"decoder.model.layers.10.self_attn.q_proj.bias": "model-00003-of-00007.safetensors",
|
| 440 |
+
"decoder.model.layers.10.self_attn.q_proj.weight": "model-00003-of-00007.safetensors",
|
| 441 |
+
"decoder.model.layers.10.self_attn.v_proj.bias": "model-00003-of-00007.safetensors",
|
| 442 |
+
"decoder.model.layers.10.self_attn.v_proj.weight": "model-00003-of-00007.safetensors",
|
| 443 |
+
"decoder.model.layers.11.input_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 444 |
+
"decoder.model.layers.11.mlp.down_proj.weight": "model-00004-of-00007.safetensors",
|
| 445 |
+
"decoder.model.layers.11.mlp.gate_proj.weight": "model-00004-of-00007.safetensors",
|
| 446 |
+
"decoder.model.layers.11.mlp.up_proj.weight": "model-00004-of-00007.safetensors",
|
| 447 |
+
"decoder.model.layers.11.post_attention_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 448 |
+
"decoder.model.layers.11.self_attn.k_proj.bias": "model-00004-of-00007.safetensors",
|
| 449 |
+
"decoder.model.layers.11.self_attn.k_proj.weight": "model-00004-of-00007.safetensors",
|
| 450 |
+
"decoder.model.layers.11.self_attn.o_proj.weight": "model-00004-of-00007.safetensors",
|
| 451 |
+
"decoder.model.layers.11.self_attn.q_proj.bias": "model-00004-of-00007.safetensors",
|
| 452 |
+
"decoder.model.layers.11.self_attn.q_proj.weight": "model-00004-of-00007.safetensors",
|
| 453 |
+
"decoder.model.layers.11.self_attn.v_proj.bias": "model-00004-of-00007.safetensors",
|
| 454 |
+
"decoder.model.layers.11.self_attn.v_proj.weight": "model-00004-of-00007.safetensors",
|
| 455 |
+
"decoder.model.layers.12.input_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 456 |
+
"decoder.model.layers.12.mlp.down_proj.weight": "model-00004-of-00007.safetensors",
|
| 457 |
+
"decoder.model.layers.12.mlp.gate_proj.weight": "model-00004-of-00007.safetensors",
|
| 458 |
+
"decoder.model.layers.12.mlp.up_proj.weight": "model-00004-of-00007.safetensors",
|
| 459 |
+
"decoder.model.layers.12.post_attention_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 460 |
+
"decoder.model.layers.12.self_attn.k_proj.bias": "model-00004-of-00007.safetensors",
|
| 461 |
+
"decoder.model.layers.12.self_attn.k_proj.weight": "model-00004-of-00007.safetensors",
|
| 462 |
+
"decoder.model.layers.12.self_attn.o_proj.weight": "model-00004-of-00007.safetensors",
|
| 463 |
+
"decoder.model.layers.12.self_attn.q_proj.bias": "model-00004-of-00007.safetensors",
|
| 464 |
+
"decoder.model.layers.12.self_attn.q_proj.weight": "model-00004-of-00007.safetensors",
|
| 465 |
+
"decoder.model.layers.12.self_attn.v_proj.bias": "model-00004-of-00007.safetensors",
|
| 466 |
+
"decoder.model.layers.12.self_attn.v_proj.weight": "model-00004-of-00007.safetensors",
|
| 467 |
+
"decoder.model.layers.13.input_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 468 |
+
"decoder.model.layers.13.mlp.down_proj.weight": "model-00004-of-00007.safetensors",
|
| 469 |
+
"decoder.model.layers.13.mlp.gate_proj.weight": "model-00004-of-00007.safetensors",
|
| 470 |
+
"decoder.model.layers.13.mlp.up_proj.weight": "model-00004-of-00007.safetensors",
|
| 471 |
+
"decoder.model.layers.13.post_attention_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 472 |
+
"decoder.model.layers.13.self_attn.k_proj.bias": "model-00004-of-00007.safetensors",
|
| 473 |
+
"decoder.model.layers.13.self_attn.k_proj.weight": "model-00004-of-00007.safetensors",
|
| 474 |
+
"decoder.model.layers.13.self_attn.o_proj.weight": "model-00004-of-00007.safetensors",
|
| 475 |
+
"decoder.model.layers.13.self_attn.q_proj.bias": "model-00004-of-00007.safetensors",
|
| 476 |
+
"decoder.model.layers.13.self_attn.q_proj.weight": "model-00004-of-00007.safetensors",
|
| 477 |
+
"decoder.model.layers.13.self_attn.v_proj.bias": "model-00004-of-00007.safetensors",
|
| 478 |
+
"decoder.model.layers.13.self_attn.v_proj.weight": "model-00004-of-00007.safetensors",
|
| 479 |
+
"decoder.model.layers.14.input_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 480 |
+
"decoder.model.layers.14.mlp.down_proj.weight": "model-00004-of-00007.safetensors",
|
| 481 |
+
"decoder.model.layers.14.mlp.gate_proj.weight": "model-00004-of-00007.safetensors",
|
| 482 |
+
"decoder.model.layers.14.mlp.up_proj.weight": "model-00004-of-00007.safetensors",
|
| 483 |
+
"decoder.model.layers.14.post_attention_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 484 |
+
"decoder.model.layers.14.self_attn.k_proj.bias": "model-00004-of-00007.safetensors",
|
| 485 |
+
"decoder.model.layers.14.self_attn.k_proj.weight": "model-00004-of-00007.safetensors",
|
| 486 |
+
"decoder.model.layers.14.self_attn.o_proj.weight": "model-00004-of-00007.safetensors",
|
| 487 |
+
"decoder.model.layers.14.self_attn.q_proj.bias": "model-00004-of-00007.safetensors",
|
| 488 |
+
"decoder.model.layers.14.self_attn.q_proj.weight": "model-00004-of-00007.safetensors",
|
| 489 |
+
"decoder.model.layers.14.self_attn.v_proj.bias": "model-00004-of-00007.safetensors",
|
| 490 |
+
"decoder.model.layers.14.self_attn.v_proj.weight": "model-00004-of-00007.safetensors",
|
| 491 |
+
"decoder.model.layers.15.input_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 492 |
+
"decoder.model.layers.15.mlp.down_proj.weight": "model-00004-of-00007.safetensors",
|
| 493 |
+
"decoder.model.layers.15.mlp.gate_proj.weight": "model-00004-of-00007.safetensors",
|
| 494 |
+
"decoder.model.layers.15.mlp.up_proj.weight": "model-00004-of-00007.safetensors",
|
| 495 |
+
"decoder.model.layers.15.post_attention_layernorm.weight": "model-00004-of-00007.safetensors",
|
| 496 |
+
"decoder.model.layers.15.self_attn.k_proj.bias": "model-00004-of-00007.safetensors",
|
| 497 |
+
"decoder.model.layers.15.self_attn.k_proj.weight": "model-00004-of-00007.safetensors",
|
| 498 |
+
"decoder.model.layers.15.self_attn.o_proj.weight": "model-00004-of-00007.safetensors",
|
| 499 |
+
"decoder.model.layers.15.self_attn.q_proj.bias": "model-00004-of-00007.safetensors",
|
| 500 |
+
"decoder.model.layers.15.self_attn.q_proj.weight": "model-00004-of-00007.safetensors",
|
| 501 |
+
"decoder.model.layers.15.self_attn.v_proj.bias": "model-00004-of-00007.safetensors",
|
| 502 |
+
"decoder.model.layers.15.self_attn.v_proj.weight": "model-00004-of-00007.safetensors",
|
| 503 |
+
"decoder.model.layers.16.input_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 504 |
+
"decoder.model.layers.16.mlp.down_proj.weight": "model-00005-of-00007.safetensors",
|
| 505 |
+
"decoder.model.layers.16.mlp.gate_proj.weight": "model-00005-of-00007.safetensors",
|
| 506 |
+
"decoder.model.layers.16.mlp.up_proj.weight": "model-00005-of-00007.safetensors",
|
| 507 |
+
"decoder.model.layers.16.post_attention_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 508 |
+
"decoder.model.layers.16.self_attn.k_proj.bias": "model-00004-of-00007.safetensors",
|
| 509 |
+
"decoder.model.layers.16.self_attn.k_proj.weight": "model-00004-of-00007.safetensors",
|
| 510 |
+
"decoder.model.layers.16.self_attn.o_proj.weight": "model-00005-of-00007.safetensors",
|
| 511 |
+
"decoder.model.layers.16.self_attn.q_proj.bias": "model-00004-of-00007.safetensors",
|
| 512 |
+
"decoder.model.layers.16.self_attn.q_proj.weight": "model-00004-of-00007.safetensors",
|
| 513 |
+
"decoder.model.layers.16.self_attn.v_proj.bias": "model-00004-of-00007.safetensors",
|
| 514 |
+
"decoder.model.layers.16.self_attn.v_proj.weight": "model-00004-of-00007.safetensors",
|
| 515 |
+
"decoder.model.layers.17.input_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 516 |
+
"decoder.model.layers.17.mlp.down_proj.weight": "model-00005-of-00007.safetensors",
|
| 517 |
+
"decoder.model.layers.17.mlp.gate_proj.weight": "model-00005-of-00007.safetensors",
|
| 518 |
+
"decoder.model.layers.17.mlp.up_proj.weight": "model-00005-of-00007.safetensors",
|
| 519 |
+
"decoder.model.layers.17.post_attention_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 520 |
+
"decoder.model.layers.17.self_attn.k_proj.bias": "model-00005-of-00007.safetensors",
|
| 521 |
+
"decoder.model.layers.17.self_attn.k_proj.weight": "model-00005-of-00007.safetensors",
|
| 522 |
+
"decoder.model.layers.17.self_attn.o_proj.weight": "model-00005-of-00007.safetensors",
|
| 523 |
+
"decoder.model.layers.17.self_attn.q_proj.bias": "model-00005-of-00007.safetensors",
|
| 524 |
+
"decoder.model.layers.17.self_attn.q_proj.weight": "model-00005-of-00007.safetensors",
|
| 525 |
+
"decoder.model.layers.17.self_attn.v_proj.bias": "model-00005-of-00007.safetensors",
|
| 526 |
+
"decoder.model.layers.17.self_attn.v_proj.weight": "model-00005-of-00007.safetensors",
|
| 527 |
+
"decoder.model.layers.18.input_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 528 |
+
"decoder.model.layers.18.mlp.down_proj.weight": "model-00005-of-00007.safetensors",
|
| 529 |
+
"decoder.model.layers.18.mlp.gate_proj.weight": "model-00005-of-00007.safetensors",
|
| 530 |
+
"decoder.model.layers.18.mlp.up_proj.weight": "model-00005-of-00007.safetensors",
|
| 531 |
+
"decoder.model.layers.18.post_attention_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 532 |
+
"decoder.model.layers.18.self_attn.k_proj.bias": "model-00005-of-00007.safetensors",
|
| 533 |
+
"decoder.model.layers.18.self_attn.k_proj.weight": "model-00005-of-00007.safetensors",
|
| 534 |
+
"decoder.model.layers.18.self_attn.o_proj.weight": "model-00005-of-00007.safetensors",
|
| 535 |
+
"decoder.model.layers.18.self_attn.q_proj.bias": "model-00005-of-00007.safetensors",
|
| 536 |
+
"decoder.model.layers.18.self_attn.q_proj.weight": "model-00005-of-00007.safetensors",
|
| 537 |
+
"decoder.model.layers.18.self_attn.v_proj.bias": "model-00005-of-00007.safetensors",
|
| 538 |
+
"decoder.model.layers.18.self_attn.v_proj.weight": "model-00005-of-00007.safetensors",
|
| 539 |
+
"decoder.model.layers.19.input_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 540 |
+
"decoder.model.layers.19.mlp.down_proj.weight": "model-00005-of-00007.safetensors",
|
| 541 |
+
"decoder.model.layers.19.mlp.gate_proj.weight": "model-00005-of-00007.safetensors",
|
| 542 |
+
"decoder.model.layers.19.mlp.up_proj.weight": "model-00005-of-00007.safetensors",
|
| 543 |
+
"decoder.model.layers.19.post_attention_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 544 |
+
"decoder.model.layers.19.self_attn.k_proj.bias": "model-00005-of-00007.safetensors",
|
| 545 |
+
"decoder.model.layers.19.self_attn.k_proj.weight": "model-00005-of-00007.safetensors",
|
| 546 |
+
"decoder.model.layers.19.self_attn.o_proj.weight": "model-00005-of-00007.safetensors",
|
| 547 |
+
"decoder.model.layers.19.self_attn.q_proj.bias": "model-00005-of-00007.safetensors",
|
| 548 |
+
"decoder.model.layers.19.self_attn.q_proj.weight": "model-00005-of-00007.safetensors",
|
| 549 |
+
"decoder.model.layers.19.self_attn.v_proj.bias": "model-00005-of-00007.safetensors",
|
| 550 |
+
"decoder.model.layers.19.self_attn.v_proj.weight": "model-00005-of-00007.safetensors",
|
| 551 |
+
"decoder.model.layers.2.input_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 552 |
+
"decoder.model.layers.2.mlp.down_proj.weight": "model-00002-of-00007.safetensors",
|
| 553 |
+
"decoder.model.layers.2.mlp.gate_proj.weight": "model-00002-of-00007.safetensors",
|
| 554 |
+
"decoder.model.layers.2.mlp.up_proj.weight": "model-00002-of-00007.safetensors",
|
| 555 |
+
"decoder.model.layers.2.post_attention_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 556 |
+
"decoder.model.layers.2.self_attn.k_proj.bias": "model-00002-of-00007.safetensors",
|
| 557 |
+
"decoder.model.layers.2.self_attn.k_proj.weight": "model-00002-of-00007.safetensors",
|
| 558 |
+
"decoder.model.layers.2.self_attn.o_proj.weight": "model-00002-of-00007.safetensors",
|
| 559 |
+
"decoder.model.layers.2.self_attn.q_proj.bias": "model-00002-of-00007.safetensors",
|
| 560 |
+
"decoder.model.layers.2.self_attn.q_proj.weight": "model-00002-of-00007.safetensors",
|
| 561 |
+
"decoder.model.layers.2.self_attn.v_proj.bias": "model-00002-of-00007.safetensors",
|
| 562 |
+
"decoder.model.layers.2.self_attn.v_proj.weight": "model-00002-of-00007.safetensors",
|
| 563 |
+
"decoder.model.layers.20.input_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 564 |
+
"decoder.model.layers.20.mlp.down_proj.weight": "model-00005-of-00007.safetensors",
|
| 565 |
+
"decoder.model.layers.20.mlp.gate_proj.weight": "model-00005-of-00007.safetensors",
|
| 566 |
+
"decoder.model.layers.20.mlp.up_proj.weight": "model-00005-of-00007.safetensors",
|
| 567 |
+
"decoder.model.layers.20.post_attention_layernorm.weight": "model-00005-of-00007.safetensors",
|
| 568 |
+
"decoder.model.layers.20.self_attn.k_proj.bias": "model-00005-of-00007.safetensors",
|
| 569 |
+
"decoder.model.layers.20.self_attn.k_proj.weight": "model-00005-of-00007.safetensors",
|
| 570 |
+
"decoder.model.layers.20.self_attn.o_proj.weight": "model-00005-of-00007.safetensors",
|
| 571 |
+
"decoder.model.layers.20.self_attn.q_proj.bias": "model-00005-of-00007.safetensors",
|
| 572 |
+
"decoder.model.layers.20.self_attn.q_proj.weight": "model-00005-of-00007.safetensors",
|
| 573 |
+
"decoder.model.layers.20.self_attn.v_proj.bias": "model-00005-of-00007.safetensors",
|
| 574 |
+
"decoder.model.layers.20.self_attn.v_proj.weight": "model-00005-of-00007.safetensors",
|
| 575 |
+
"decoder.model.layers.21.input_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 576 |
+
"decoder.model.layers.21.mlp.down_proj.weight": "model-00006-of-00007.safetensors",
|
| 577 |
+
"decoder.model.layers.21.mlp.gate_proj.weight": "model-00005-of-00007.safetensors",
|
| 578 |
+
"decoder.model.layers.21.mlp.up_proj.weight": "model-00006-of-00007.safetensors",
|
| 579 |
+
"decoder.model.layers.21.post_attention_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 580 |
+
"decoder.model.layers.21.self_attn.k_proj.bias": "model-00005-of-00007.safetensors",
|
| 581 |
+
"decoder.model.layers.21.self_attn.k_proj.weight": "model-00005-of-00007.safetensors",
|
| 582 |
+
"decoder.model.layers.21.self_attn.o_proj.weight": "model-00005-of-00007.safetensors",
|
| 583 |
+
"decoder.model.layers.21.self_attn.q_proj.bias": "model-00005-of-00007.safetensors",
|
| 584 |
+
"decoder.model.layers.21.self_attn.q_proj.weight": "model-00005-of-00007.safetensors",
|
| 585 |
+
"decoder.model.layers.21.self_attn.v_proj.bias": "model-00005-of-00007.safetensors",
|
| 586 |
+
"decoder.model.layers.21.self_attn.v_proj.weight": "model-00005-of-00007.safetensors",
|
| 587 |
+
"decoder.model.layers.22.input_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 588 |
+
"decoder.model.layers.22.mlp.down_proj.weight": "model-00006-of-00007.safetensors",
|
| 589 |
+
"decoder.model.layers.22.mlp.gate_proj.weight": "model-00006-of-00007.safetensors",
|
| 590 |
+
"decoder.model.layers.22.mlp.up_proj.weight": "model-00006-of-00007.safetensors",
|
| 591 |
+
"decoder.model.layers.22.post_attention_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 592 |
+
"decoder.model.layers.22.self_attn.k_proj.bias": "model-00006-of-00007.safetensors",
|
| 593 |
+
"decoder.model.layers.22.self_attn.k_proj.weight": "model-00006-of-00007.safetensors",
|
| 594 |
+
"decoder.model.layers.22.self_attn.o_proj.weight": "model-00006-of-00007.safetensors",
|
| 595 |
+
"decoder.model.layers.22.self_attn.q_proj.bias": "model-00006-of-00007.safetensors",
|
| 596 |
+
"decoder.model.layers.22.self_attn.q_proj.weight": "model-00006-of-00007.safetensors",
|
| 597 |
+
"decoder.model.layers.22.self_attn.v_proj.bias": "model-00006-of-00007.safetensors",
|
| 598 |
+
"decoder.model.layers.22.self_attn.v_proj.weight": "model-00006-of-00007.safetensors",
|
| 599 |
+
"decoder.model.layers.23.input_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 600 |
+
"decoder.model.layers.23.mlp.down_proj.weight": "model-00006-of-00007.safetensors",
|
| 601 |
+
"decoder.model.layers.23.mlp.gate_proj.weight": "model-00006-of-00007.safetensors",
|
| 602 |
+
"decoder.model.layers.23.mlp.up_proj.weight": "model-00006-of-00007.safetensors",
|
| 603 |
+
"decoder.model.layers.23.post_attention_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 604 |
+
"decoder.model.layers.23.self_attn.k_proj.bias": "model-00006-of-00007.safetensors",
|
| 605 |
+
"decoder.model.layers.23.self_attn.k_proj.weight": "model-00006-of-00007.safetensors",
|
| 606 |
+
"decoder.model.layers.23.self_attn.o_proj.weight": "model-00006-of-00007.safetensors",
|
| 607 |
+
"decoder.model.layers.23.self_attn.q_proj.bias": "model-00006-of-00007.safetensors",
|
| 608 |
+
"decoder.model.layers.23.self_attn.q_proj.weight": "model-00006-of-00007.safetensors",
|
| 609 |
+
"decoder.model.layers.23.self_attn.v_proj.bias": "model-00006-of-00007.safetensors",
|
| 610 |
+
"decoder.model.layers.23.self_attn.v_proj.weight": "model-00006-of-00007.safetensors",
|
| 611 |
+
"decoder.model.layers.24.input_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 612 |
+
"decoder.model.layers.24.mlp.down_proj.weight": "model-00006-of-00007.safetensors",
|
| 613 |
+
"decoder.model.layers.24.mlp.gate_proj.weight": "model-00006-of-00007.safetensors",
|
| 614 |
+
"decoder.model.layers.24.mlp.up_proj.weight": "model-00006-of-00007.safetensors",
|
| 615 |
+
"decoder.model.layers.24.post_attention_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 616 |
+
"decoder.model.layers.24.self_attn.k_proj.bias": "model-00006-of-00007.safetensors",
|
| 617 |
+
"decoder.model.layers.24.self_attn.k_proj.weight": "model-00006-of-00007.safetensors",
|
| 618 |
+
"decoder.model.layers.24.self_attn.o_proj.weight": "model-00006-of-00007.safetensors",
|
| 619 |
+
"decoder.model.layers.24.self_attn.q_proj.bias": "model-00006-of-00007.safetensors",
|
| 620 |
+
"decoder.model.layers.24.self_attn.q_proj.weight": "model-00006-of-00007.safetensors",
|
| 621 |
+
"decoder.model.layers.24.self_attn.v_proj.bias": "model-00006-of-00007.safetensors",
|
| 622 |
+
"decoder.model.layers.24.self_attn.v_proj.weight": "model-00006-of-00007.safetensors",
|
| 623 |
+
"decoder.model.layers.25.input_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 624 |
+
"decoder.model.layers.25.mlp.down_proj.weight": "model-00006-of-00007.safetensors",
|
| 625 |
+
"decoder.model.layers.25.mlp.gate_proj.weight": "model-00006-of-00007.safetensors",
|
| 626 |
+
"decoder.model.layers.25.mlp.up_proj.weight": "model-00006-of-00007.safetensors",
|
| 627 |
+
"decoder.model.layers.25.post_attention_layernorm.weight": "model-00006-of-00007.safetensors",
|
| 628 |
+
"decoder.model.layers.25.self_attn.k_proj.bias": "model-00006-of-00007.safetensors",
|
| 629 |
+
"decoder.model.layers.25.self_attn.k_proj.weight": "model-00006-of-00007.safetensors",
|
| 630 |
+
"decoder.model.layers.25.self_attn.o_proj.weight": "model-00006-of-00007.safetensors",
|
| 631 |
+
"decoder.model.layers.25.self_attn.q_proj.bias": "model-00006-of-00007.safetensors",
|
| 632 |
+
"decoder.model.layers.25.self_attn.q_proj.weight": "model-00006-of-00007.safetensors",
|
| 633 |
+
"decoder.model.layers.25.self_attn.v_proj.bias": "model-00006-of-00007.safetensors",
|
| 634 |
+
"decoder.model.layers.25.self_attn.v_proj.weight": "model-00006-of-00007.safetensors",
|
| 635 |
+
"decoder.model.layers.26.input_layernorm.weight": "model-00007-of-00007.safetensors",
|
| 636 |
+
"decoder.model.layers.26.mlp.down_proj.weight": "model-00007-of-00007.safetensors",
|
| 637 |
+
"decoder.model.layers.26.mlp.gate_proj.weight": "model-00006-of-00007.safetensors",
|
| 638 |
+
"decoder.model.layers.26.mlp.up_proj.weight": "model-00006-of-00007.safetensors",
|
| 639 |
+
"decoder.model.layers.26.post_attention_layernorm.weight": "model-00007-of-00007.safetensors",
|
| 640 |
+
"decoder.model.layers.26.self_attn.k_proj.bias": "model-00006-of-00007.safetensors",
|
| 641 |
+
"decoder.model.layers.26.self_attn.k_proj.weight": "model-00006-of-00007.safetensors",
|
| 642 |
+
"decoder.model.layers.26.self_attn.o_proj.weight": "model-00006-of-00007.safetensors",
|
| 643 |
+
"decoder.model.layers.26.self_attn.q_proj.bias": "model-00006-of-00007.safetensors",
|
| 644 |
+
"decoder.model.layers.26.self_attn.q_proj.weight": "model-00006-of-00007.safetensors",
|
| 645 |
+
"decoder.model.layers.26.self_attn.v_proj.bias": "model-00006-of-00007.safetensors",
|
| 646 |
+
"decoder.model.layers.26.self_attn.v_proj.weight": "model-00006-of-00007.safetensors",
|
| 647 |
+
"decoder.model.layers.27.input_layernorm.weight": "model-00007-of-00007.safetensors",
|
| 648 |
+
"decoder.model.layers.27.mlp.down_proj.weight": "model-00007-of-00007.safetensors",
|
| 649 |
+
"decoder.model.layers.27.mlp.gate_proj.weight": "model-00007-of-00007.safetensors",
|
| 650 |
+
"decoder.model.layers.27.mlp.up_proj.weight": "model-00007-of-00007.safetensors",
|
| 651 |
+
"decoder.model.layers.27.post_attention_layernorm.weight": "model-00007-of-00007.safetensors",
|
| 652 |
+
"decoder.model.layers.27.self_attn.k_proj.bias": "model-00007-of-00007.safetensors",
|
| 653 |
+
"decoder.model.layers.27.self_attn.k_proj.weight": "model-00007-of-00007.safetensors",
|
| 654 |
+
"decoder.model.layers.27.self_attn.o_proj.weight": "model-00007-of-00007.safetensors",
|
| 655 |
+
"decoder.model.layers.27.self_attn.q_proj.bias": "model-00007-of-00007.safetensors",
|
| 656 |
+
"decoder.model.layers.27.self_attn.q_proj.weight": "model-00007-of-00007.safetensors",
|
| 657 |
+
"decoder.model.layers.27.self_attn.v_proj.bias": "model-00007-of-00007.safetensors",
|
| 658 |
+
"decoder.model.layers.27.self_attn.v_proj.weight": "model-00007-of-00007.safetensors",
|
| 659 |
+
"decoder.model.layers.3.input_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 660 |
+
"decoder.model.layers.3.mlp.down_proj.weight": "model-00002-of-00007.safetensors",
|
| 661 |
+
"decoder.model.layers.3.mlp.gate_proj.weight": "model-00002-of-00007.safetensors",
|
| 662 |
+
"decoder.model.layers.3.mlp.up_proj.weight": "model-00002-of-00007.safetensors",
|
| 663 |
+
"decoder.model.layers.3.post_attention_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 664 |
+
"decoder.model.layers.3.self_attn.k_proj.bias": "model-00002-of-00007.safetensors",
|
| 665 |
+
"decoder.model.layers.3.self_attn.k_proj.weight": "model-00002-of-00007.safetensors",
|
| 666 |
+
"decoder.model.layers.3.self_attn.o_proj.weight": "model-00002-of-00007.safetensors",
|
| 667 |
+
"decoder.model.layers.3.self_attn.q_proj.bias": "model-00002-of-00007.safetensors",
|
| 668 |
+
"decoder.model.layers.3.self_attn.q_proj.weight": "model-00002-of-00007.safetensors",
|
| 669 |
+
"decoder.model.layers.3.self_attn.v_proj.bias": "model-00002-of-00007.safetensors",
|
| 670 |
+
"decoder.model.layers.3.self_attn.v_proj.weight": "model-00002-of-00007.safetensors",
|
| 671 |
+
"decoder.model.layers.4.input_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 672 |
+
"decoder.model.layers.4.mlp.down_proj.weight": "model-00002-of-00007.safetensors",
|
| 673 |
+
"decoder.model.layers.4.mlp.gate_proj.weight": "model-00002-of-00007.safetensors",
|
| 674 |
+
"decoder.model.layers.4.mlp.up_proj.weight": "model-00002-of-00007.safetensors",
|
| 675 |
+
"decoder.model.layers.4.post_attention_layernorm.weight": "model-00002-of-00007.safetensors",
|
| 676 |
+
"decoder.model.layers.4.self_attn.k_proj.bias": "model-00002-of-00007.safetensors",
|
| 677 |
+
"decoder.model.layers.4.self_attn.k_proj.weight": "model-00002-of-00007.safetensors",
|
| 678 |
+
"decoder.model.layers.4.self_attn.o_proj.weight": "model-00002-of-00007.safetensors",
|
| 679 |
+
"decoder.model.layers.4.self_attn.q_proj.bias": "model-00002-of-00007.safetensors",
|
| 680 |
+
"decoder.model.layers.4.self_attn.q_proj.weight": "model-00002-of-00007.safetensors",
|
| 681 |
+
"decoder.model.layers.4.self_attn.v_proj.bias": "model-00002-of-00007.safetensors",
|
| 682 |
+
"decoder.model.layers.4.self_attn.v_proj.weight": "model-00002-of-00007.safetensors",
|
| 683 |
+
"decoder.model.layers.5.input_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 684 |
+
"decoder.model.layers.5.mlp.down_proj.weight": "model-00003-of-00007.safetensors",
|
| 685 |
+
"decoder.model.layers.5.mlp.gate_proj.weight": "model-00002-of-00007.safetensors",
|
| 686 |
+
"decoder.model.layers.5.mlp.up_proj.weight": "model-00003-of-00007.safetensors",
|
| 687 |
+
"decoder.model.layers.5.post_attention_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 688 |
+
"decoder.model.layers.5.self_attn.k_proj.bias": "model-00002-of-00007.safetensors",
|
| 689 |
+
"decoder.model.layers.5.self_attn.k_proj.weight": "model-00002-of-00007.safetensors",
|
| 690 |
+
"decoder.model.layers.5.self_attn.o_proj.weight": "model-00002-of-00007.safetensors",
|
| 691 |
+
"decoder.model.layers.5.self_attn.q_proj.bias": "model-00002-of-00007.safetensors",
|
| 692 |
+
"decoder.model.layers.5.self_attn.q_proj.weight": "model-00002-of-00007.safetensors",
|
| 693 |
+
"decoder.model.layers.5.self_attn.v_proj.bias": "model-00002-of-00007.safetensors",
|
| 694 |
+
"decoder.model.layers.5.self_attn.v_proj.weight": "model-00002-of-00007.safetensors",
|
| 695 |
+
"decoder.model.layers.6.input_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 696 |
+
"decoder.model.layers.6.mlp.down_proj.weight": "model-00003-of-00007.safetensors",
|
| 697 |
+
"decoder.model.layers.6.mlp.gate_proj.weight": "model-00003-of-00007.safetensors",
|
| 698 |
+
"decoder.model.layers.6.mlp.up_proj.weight": "model-00003-of-00007.safetensors",
|
| 699 |
+
"decoder.model.layers.6.post_attention_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 700 |
+
"decoder.model.layers.6.self_attn.k_proj.bias": "model-00003-of-00007.safetensors",
|
| 701 |
+
"decoder.model.layers.6.self_attn.k_proj.weight": "model-00003-of-00007.safetensors",
|
| 702 |
+
"decoder.model.layers.6.self_attn.o_proj.weight": "model-00003-of-00007.safetensors",
|
| 703 |
+
"decoder.model.layers.6.self_attn.q_proj.bias": "model-00003-of-00007.safetensors",
|
| 704 |
+
"decoder.model.layers.6.self_attn.q_proj.weight": "model-00003-of-00007.safetensors",
|
| 705 |
+
"decoder.model.layers.6.self_attn.v_proj.bias": "model-00003-of-00007.safetensors",
|
| 706 |
+
"decoder.model.layers.6.self_attn.v_proj.weight": "model-00003-of-00007.safetensors",
|
| 707 |
+
"decoder.model.layers.7.input_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 708 |
+
"decoder.model.layers.7.mlp.down_proj.weight": "model-00003-of-00007.safetensors",
|
| 709 |
+
"decoder.model.layers.7.mlp.gate_proj.weight": "model-00003-of-00007.safetensors",
|
| 710 |
+
"decoder.model.layers.7.mlp.up_proj.weight": "model-00003-of-00007.safetensors",
|
| 711 |
+
"decoder.model.layers.7.post_attention_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 712 |
+
"decoder.model.layers.7.self_attn.k_proj.bias": "model-00003-of-00007.safetensors",
|
| 713 |
+
"decoder.model.layers.7.self_attn.k_proj.weight": "model-00003-of-00007.safetensors",
|
| 714 |
+
"decoder.model.layers.7.self_attn.o_proj.weight": "model-00003-of-00007.safetensors",
|
| 715 |
+
"decoder.model.layers.7.self_attn.q_proj.bias": "model-00003-of-00007.safetensors",
|
| 716 |
+
"decoder.model.layers.7.self_attn.q_proj.weight": "model-00003-of-00007.safetensors",
|
| 717 |
+
"decoder.model.layers.7.self_attn.v_proj.bias": "model-00003-of-00007.safetensors",
|
| 718 |
+
"decoder.model.layers.7.self_attn.v_proj.weight": "model-00003-of-00007.safetensors",
|
| 719 |
+
"decoder.model.layers.8.input_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 720 |
+
"decoder.model.layers.8.mlp.down_proj.weight": "model-00003-of-00007.safetensors",
|
| 721 |
+
"decoder.model.layers.8.mlp.gate_proj.weight": "model-00003-of-00007.safetensors",
|
| 722 |
+
"decoder.model.layers.8.mlp.up_proj.weight": "model-00003-of-00007.safetensors",
|
| 723 |
+
"decoder.model.layers.8.post_attention_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 724 |
+
"decoder.model.layers.8.self_attn.k_proj.bias": "model-00003-of-00007.safetensors",
|
| 725 |
+
"decoder.model.layers.8.self_attn.k_proj.weight": "model-00003-of-00007.safetensors",
|
| 726 |
+
"decoder.model.layers.8.self_attn.o_proj.weight": "model-00003-of-00007.safetensors",
|
| 727 |
+
"decoder.model.layers.8.self_attn.q_proj.bias": "model-00003-of-00007.safetensors",
|
| 728 |
+
"decoder.model.layers.8.self_attn.q_proj.weight": "model-00003-of-00007.safetensors",
|
| 729 |
+
"decoder.model.layers.8.self_attn.v_proj.bias": "model-00003-of-00007.safetensors",
|
| 730 |
+
"decoder.model.layers.8.self_attn.v_proj.weight": "model-00003-of-00007.safetensors",
|
| 731 |
+
"decoder.model.layers.9.input_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 732 |
+
"decoder.model.layers.9.mlp.down_proj.weight": "model-00003-of-00007.safetensors",
|
| 733 |
+
"decoder.model.layers.9.mlp.gate_proj.weight": "model-00003-of-00007.safetensors",
|
| 734 |
+
"decoder.model.layers.9.mlp.up_proj.weight": "model-00003-of-00007.safetensors",
|
| 735 |
+
"decoder.model.layers.9.post_attention_layernorm.weight": "model-00003-of-00007.safetensors",
|
| 736 |
+
"decoder.model.layers.9.self_attn.k_proj.bias": "model-00003-of-00007.safetensors",
|
| 737 |
+
"decoder.model.layers.9.self_attn.k_proj.weight": "model-00003-of-00007.safetensors",
|
| 738 |
+
"decoder.model.layers.9.self_attn.o_proj.weight": "model-00003-of-00007.safetensors",
|
| 739 |
+
"decoder.model.layers.9.self_attn.q_proj.bias": "model-00003-of-00007.safetensors",
|
| 740 |
+
"decoder.model.layers.9.self_attn.q_proj.weight": "model-00003-of-00007.safetensors",
|
| 741 |
+
"decoder.model.layers.9.self_attn.v_proj.bias": "model-00003-of-00007.safetensors",
|
| 742 |
+
"decoder.model.layers.9.self_attn.v_proj.weight": "model-00003-of-00007.safetensors",
|
| 743 |
+
"decoder.model.norm.weight": "model-00007-of-00007.safetensors"
|
| 744 |
+
}
|
| 745 |
+
}
|
modeling_midashenglm.py
ADDED
|
@@ -0,0 +1,636 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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, Callable, Iterable, List, Optional, Sequence, Tuple, Union, cast
|
| 5 |
+
|
| 6 |
+
import torch
|
| 7 |
+
import torch.nn as nn
|
| 8 |
+
import torchaudio.functional as F
|
| 9 |
+
from torch import Tensor
|
| 10 |
+
from torch.nn.functional import scaled_dot_product_attention
|
| 11 |
+
from transformers import GenerationMixin, PreTrainedModel
|
| 12 |
+
from transformers.cache_utils import Cache
|
| 13 |
+
from transformers.modeling_outputs import BaseModelOutputWithPast, ModelOutput
|
| 14 |
+
from transformers.models.qwen2_5_omni.configuration_qwen2_5_omni import (
|
| 15 |
+
Qwen2_5OmniTextConfig,
|
| 16 |
+
)
|
| 17 |
+
from transformers.models.qwen2_5_omni.modeling_qwen2_5_omni import (
|
| 18 |
+
Qwen2_5OmniThinkerTextModel,
|
| 19 |
+
)
|
| 20 |
+
from transformers.utils import can_return_tuple
|
| 21 |
+
|
| 22 |
+
from .configuration_midashenglm import DashengConfig, MiDashengLMConfig
|
| 23 |
+
|
| 24 |
+
_Tuple2 = Union[int, Tuple[int, int], Sequence[int]]
|
| 25 |
+
|
| 26 |
+
|
| 27 |
+
def _resolve_tuple2(x: _Tuple2) -> Tuple[int, int]:
|
| 28 |
+
if isinstance(x, collections.abc.Sequence):
|
| 29 |
+
assert len(x) == 2, (
|
| 30 |
+
f"Expected a sequence of length 2, got {x} with length {len(x)}"
|
| 31 |
+
)
|
| 32 |
+
return cast(Tuple[int, int], tuple(x))
|
| 33 |
+
return (x, x)
|
| 34 |
+
|
| 35 |
+
|
| 36 |
+
class AudioPatchEmbed(nn.Module):
|
| 37 |
+
def __init__(
|
| 38 |
+
self,
|
| 39 |
+
input_size: _Tuple2 = 64,
|
| 40 |
+
patch_size: _Tuple2 = 16,
|
| 41 |
+
patch_stride: _Tuple2 = 16,
|
| 42 |
+
in_chans: int = 1,
|
| 43 |
+
embed_dim: int = 768,
|
| 44 |
+
norm_layer: Optional[Callable] = None,
|
| 45 |
+
flatten: bool = False,
|
| 46 |
+
):
|
| 47 |
+
super().__init__()
|
| 48 |
+
self.input_size = _resolve_tuple2(input_size)
|
| 49 |
+
self.patch_size = _resolve_tuple2(patch_size)
|
| 50 |
+
self.patch_stride = _resolve_tuple2(patch_stride)
|
| 51 |
+
self.grid_size = (
|
| 52 |
+
self.input_size[0] // self.patch_stride[0],
|
| 53 |
+
self.input_size[1] // self.patch_stride[1],
|
| 54 |
+
)
|
| 55 |
+
self.num_patches = self.grid_size[0] * self.grid_size[1]
|
| 56 |
+
self.flatten = flatten
|
| 57 |
+
|
| 58 |
+
self.proj = nn.Conv2d(
|
| 59 |
+
in_chans,
|
| 60 |
+
embed_dim,
|
| 61 |
+
kernel_size=self.patch_size,
|
| 62 |
+
stride=self.patch_stride,
|
| 63 |
+
)
|
| 64 |
+
self.norm = norm_layer(embed_dim) if norm_layer else nn.Identity()
|
| 65 |
+
|
| 66 |
+
def forward(self, x: torch.Tensor) -> torch.Tensor:
|
| 67 |
+
x = self.proj(x)
|
| 68 |
+
if self.flatten:
|
| 69 |
+
x = torch.permute(
|
| 70 |
+
torch.flatten(x, 2, 3), (0, 2, 1)
|
| 71 |
+
) # rearrange(x, "b c f t -> b (f t) c")
|
| 72 |
+
x = self.norm(x)
|
| 73 |
+
return x
|
| 74 |
+
|
| 75 |
+
|
| 76 |
+
class LayerScale(nn.Module):
|
| 77 |
+
def __init__(self, dim, init_values=1e-5, inplace=False):
|
| 78 |
+
super().__init__()
|
| 79 |
+
self.inplace = inplace
|
| 80 |
+
self.gamma = nn.Parameter(init_values * torch.ones(dim))
|
| 81 |
+
|
| 82 |
+
def forward(self, x: torch.Tensor) -> torch.Tensor:
|
| 83 |
+
return x.mul_(self.gamma) if self.inplace else x * self.gamma
|
| 84 |
+
|
| 85 |
+
|
| 86 |
+
class DashengMlp(nn.Module):
|
| 87 |
+
def __init__(
|
| 88 |
+
self,
|
| 89 |
+
in_features: int,
|
| 90 |
+
hidden_features: Optional[int] = None,
|
| 91 |
+
out_features: Optional[int] = None,
|
| 92 |
+
drop: float = 0.0,
|
| 93 |
+
):
|
| 94 |
+
super().__init__()
|
| 95 |
+
out_features = out_features or in_features
|
| 96 |
+
hidden_features = hidden_features or in_features
|
| 97 |
+
self.fc1 = nn.Linear(in_features, hidden_features)
|
| 98 |
+
self.act = nn.GELU()
|
| 99 |
+
self.fc2 = nn.Linear(hidden_features, out_features)
|
| 100 |
+
self.drop = nn.Dropout(drop)
|
| 101 |
+
|
| 102 |
+
def forward(self, x: torch.Tensor) -> torch.Tensor:
|
| 103 |
+
x = self.fc1(x)
|
| 104 |
+
x = self.act(x)
|
| 105 |
+
x = self.drop(x)
|
| 106 |
+
x = self.fc2(x)
|
| 107 |
+
x = self.drop(x)
|
| 108 |
+
return x
|
| 109 |
+
|
| 110 |
+
|
| 111 |
+
class DashengAttention(nn.Module):
|
| 112 |
+
def __init__(
|
| 113 |
+
self,
|
| 114 |
+
dim: int,
|
| 115 |
+
num_heads: int = 8,
|
| 116 |
+
qkv_bias: bool = False,
|
| 117 |
+
attn_drop: float = 0.0,
|
| 118 |
+
proj_drop: float = 0.0,
|
| 119 |
+
):
|
| 120 |
+
super().__init__()
|
| 121 |
+
assert dim % num_heads == 0, "dim should be divisible by num_heads"
|
| 122 |
+
self.num_heads = num_heads
|
| 123 |
+
head_dim = dim // num_heads
|
| 124 |
+
self.scale = head_dim**-0.5
|
| 125 |
+
|
| 126 |
+
self.qkv = nn.Linear(dim, dim * 3, bias=qkv_bias)
|
| 127 |
+
self.attn_drop = nn.Dropout(attn_drop)
|
| 128 |
+
self.proj = nn.Linear(dim, dim)
|
| 129 |
+
self.proj_drop = nn.Dropout(proj_drop)
|
| 130 |
+
|
| 131 |
+
def forward(self, x: torch.Tensor, mask: Optional[torch.Tensor] = None):
|
| 132 |
+
B, N, C = x.shape
|
| 133 |
+
q, k, v = (
|
| 134 |
+
self.qkv(x)
|
| 135 |
+
.reshape(B, N, 3, self.num_heads, C // self.num_heads)
|
| 136 |
+
.permute(2, 0, 3, 1, 4)
|
| 137 |
+
.unbind(0)
|
| 138 |
+
)
|
| 139 |
+
x = scaled_dot_product_attention(
|
| 140 |
+
q,
|
| 141 |
+
k,
|
| 142 |
+
v,
|
| 143 |
+
attn_mask=mask[:, None, None, :] if mask is not None else None,
|
| 144 |
+
)
|
| 145 |
+
x = x.transpose(1, 2).reshape(B, N, C)
|
| 146 |
+
x = self.proj(x)
|
| 147 |
+
x = self.proj_drop(x)
|
| 148 |
+
return x
|
| 149 |
+
|
| 150 |
+
|
| 151 |
+
class DashengBlock(nn.Module):
|
| 152 |
+
def __init__(
|
| 153 |
+
self,
|
| 154 |
+
dim: int,
|
| 155 |
+
num_heads: int,
|
| 156 |
+
mlp_ratio: float = 4.0,
|
| 157 |
+
qkv_bias: bool = False,
|
| 158 |
+
drop: float = 0.0,
|
| 159 |
+
attn_drop: float = 0.0,
|
| 160 |
+
init_values: Optional[float] = None,
|
| 161 |
+
):
|
| 162 |
+
super().__init__()
|
| 163 |
+
self.norm1 = nn.LayerNorm(dim, eps=1e-6)
|
| 164 |
+
self.attn = DashengAttention(
|
| 165 |
+
dim,
|
| 166 |
+
num_heads=num_heads,
|
| 167 |
+
qkv_bias=qkv_bias,
|
| 168 |
+
attn_drop=attn_drop,
|
| 169 |
+
proj_drop=drop,
|
| 170 |
+
)
|
| 171 |
+
self.ls1 = (
|
| 172 |
+
LayerScale(dim, init_values=init_values) if init_values else nn.Identity()
|
| 173 |
+
)
|
| 174 |
+
|
| 175 |
+
self.norm2 = nn.LayerNorm(dim, eps=1e-6)
|
| 176 |
+
self.mlp = DashengMlp(
|
| 177 |
+
in_features=dim,
|
| 178 |
+
hidden_features=int(dim * mlp_ratio),
|
| 179 |
+
drop=drop,
|
| 180 |
+
)
|
| 181 |
+
self.ls2 = (
|
| 182 |
+
LayerScale(dim, init_values=init_values) if init_values else nn.Identity()
|
| 183 |
+
)
|
| 184 |
+
|
| 185 |
+
# Kwargs usually has a mask parameter that is passed to Attention
|
| 186 |
+
def forward(
|
| 187 |
+
self,
|
| 188 |
+
x: torch.Tensor,
|
| 189 |
+
mask: Optional[torch.Tensor] = None,
|
| 190 |
+
) -> torch.Tensor:
|
| 191 |
+
x = x + self.ls1(self.attn(self.norm1(x), mask))
|
| 192 |
+
x = x + self.ls2(self.mlp(self.norm2(x)))
|
| 193 |
+
return x
|
| 194 |
+
|
| 195 |
+
|
| 196 |
+
class DashengFrontend(nn.Module):
|
| 197 |
+
def __init__(self, config: DashengConfig):
|
| 198 |
+
super().__init__()
|
| 199 |
+
self.config = config
|
| 200 |
+
|
| 201 |
+
spectrogram_window = torch.hann_window(self.config.win_length)
|
| 202 |
+
self.register_buffer(
|
| 203 |
+
"spectrogram_window",
|
| 204 |
+
spectrogram_window,
|
| 205 |
+
persistent=False,
|
| 206 |
+
)
|
| 207 |
+
self.spectrogram_window: torch.Tensor
|
| 208 |
+
|
| 209 |
+
melscale_fbanks = F.melscale_fbanks(
|
| 210 |
+
n_freqs=self.config.n_fft // 2 + 1,
|
| 211 |
+
f_min=self.config.f_min,
|
| 212 |
+
f_max=self.config.f_max,
|
| 213 |
+
n_mels=self.config.n_mels,
|
| 214 |
+
sample_rate=self.config.sample_rate,
|
| 215 |
+
)
|
| 216 |
+
self.register_buffer("melscale_fbanks", melscale_fbanks, persistent=False)
|
| 217 |
+
self.melscale_fbanks: torch.Tensor
|
| 218 |
+
|
| 219 |
+
def forward(self, waveform: torch.Tensor) -> torch.Tensor:
|
| 220 |
+
spectrogram = F.spectrogram(
|
| 221 |
+
waveform=waveform.to(torch.float32),
|
| 222 |
+
pad=0,
|
| 223 |
+
window=self.spectrogram_window,
|
| 224 |
+
n_fft=self.config.n_fft,
|
| 225 |
+
hop_length=self.config.hop_length,
|
| 226 |
+
win_length=self.config.win_length,
|
| 227 |
+
power=2,
|
| 228 |
+
normalized=False,
|
| 229 |
+
center=self.config.center,
|
| 230 |
+
)
|
| 231 |
+
mel_spectrogram = (spectrogram.mT @ self.melscale_fbanks.to(torch.float32)).mT
|
| 232 |
+
# x has shape [batch, freq, time].
|
| 233 |
+
# F.amplitude_to_DB accepts inputs shaped as:
|
| 234 |
+
# - [freq, time]
|
| 235 |
+
# - [channel, freq, time]
|
| 236 |
+
# - [..., channel, freq, time]
|
| 237 |
+
# Here we insert a channel dimension of size 1 before calling it,
|
| 238 |
+
# then remove that extra dimension afterward.
|
| 239 |
+
log_mel_spectrogram = F.amplitude_to_DB(
|
| 240 |
+
mel_spectrogram.unsqueeze(1),
|
| 241 |
+
multiplier=10,
|
| 242 |
+
amin=1e-10,
|
| 243 |
+
db_multiplier=0,
|
| 244 |
+
top_db=120,
|
| 245 |
+
).squeeze(1)
|
| 246 |
+
return log_mel_spectrogram.to(waveform.dtype)
|
| 247 |
+
|
| 248 |
+
|
| 249 |
+
class DashengAudioTransformer(PreTrainedModel):
|
| 250 |
+
config_class = DashengConfig
|
| 251 |
+
supports_gradient_checkpointing = True
|
| 252 |
+
|
| 253 |
+
def __init__(self, config: DashengConfig):
|
| 254 |
+
super().__init__(config)
|
| 255 |
+
|
| 256 |
+
self.target_length = config.target_length
|
| 257 |
+
self.embed_dim = config.embed_dim
|
| 258 |
+
self.hop_length = config.hop_length
|
| 259 |
+
self.gradient_checkpointing = False
|
| 260 |
+
|
| 261 |
+
self.front_end = DashengFrontend(config)
|
| 262 |
+
|
| 263 |
+
self.init_bn = nn.BatchNorm2d(config.n_mels, momentum=0.01)
|
| 264 |
+
|
| 265 |
+
self.patch_embed = AudioPatchEmbed(
|
| 266 |
+
input_size=(config.n_mels, config.target_length),
|
| 267 |
+
embed_dim=config.embed_dim,
|
| 268 |
+
in_chans=config.input_channels,
|
| 269 |
+
patch_size=config.patch_size,
|
| 270 |
+
flatten=False,
|
| 271 |
+
patch_stride=config.patch_stride,
|
| 272 |
+
)
|
| 273 |
+
|
| 274 |
+
self.time_pos_embed = nn.Parameter(
|
| 275 |
+
torch.randn(1, config.embed_dim, 1, self.patch_embed.grid_size[1]) * 0.02
|
| 276 |
+
)
|
| 277 |
+
self.freq_pos_embed = nn.Parameter(
|
| 278 |
+
torch.randn(1, config.embed_dim, self.patch_embed.grid_size[0], 1) * 0.02
|
| 279 |
+
)
|
| 280 |
+
|
| 281 |
+
self.pos_drop = nn.Dropout(p=config.drop_rate)
|
| 282 |
+
self.blocks = nn.ModuleList(
|
| 283 |
+
DashengBlock(
|
| 284 |
+
dim=config.embed_dim,
|
| 285 |
+
num_heads=config.num_heads,
|
| 286 |
+
mlp_ratio=config.mlp_ratio,
|
| 287 |
+
qkv_bias=config.qkv_bias,
|
| 288 |
+
init_values=config.init_values,
|
| 289 |
+
drop=config.drop_rate,
|
| 290 |
+
attn_drop=config.attn_drop_rate,
|
| 291 |
+
)
|
| 292 |
+
for _ in range(config.depth)
|
| 293 |
+
)
|
| 294 |
+
self.norm = nn.LayerNorm(config.embed_dim, eps=1e-6)
|
| 295 |
+
|
| 296 |
+
self.post_init()
|
| 297 |
+
|
| 298 |
+
def forward_features(
|
| 299 |
+
self,
|
| 300 |
+
x: torch.Tensor,
|
| 301 |
+
mask: Optional[torch.Tensor] = None,
|
| 302 |
+
) -> torch.Tensor:
|
| 303 |
+
t = x.shape[-1]
|
| 304 |
+
x = x + self.time_pos_embed[:, :, :, :t]
|
| 305 |
+
x = (
|
| 306 |
+
x + self.freq_pos_embed[:, :, :, :]
|
| 307 |
+
) # Just to support __getitem__ in posembed
|
| 308 |
+
x = torch.permute(
|
| 309 |
+
torch.flatten(x, 2, 3), (0, 2, 1)
|
| 310 |
+
) # rearrange(x, "b c f t -> b (f t) c")
|
| 311 |
+
x = self.pos_drop(x)
|
| 312 |
+
for block in self.blocks:
|
| 313 |
+
if self.gradient_checkpointing and self.training:
|
| 314 |
+
x = self._gradient_checkpointing_func(block, x, mask)
|
| 315 |
+
else:
|
| 316 |
+
x = block(x, mask)
|
| 317 |
+
x = self.norm(x)
|
| 318 |
+
return x
|
| 319 |
+
|
| 320 |
+
def _to_mask(self, lengths: torch.Tensor, max_length: int) -> torch.Tensor:
|
| 321 |
+
batch_size = len(lengths)
|
| 322 |
+
idx = torch.arange(max_length, device=lengths.device)
|
| 323 |
+
idx = idx.repeat(batch_size).view(batch_size, max_length)
|
| 324 |
+
mask = (idx < lengths.unsqueeze(-1)).bool()
|
| 325 |
+
return mask
|
| 326 |
+
|
| 327 |
+
def forward(
|
| 328 |
+
self,
|
| 329 |
+
x: torch.Tensor,
|
| 330 |
+
x_length: Optional[torch.Tensor] = None,
|
| 331 |
+
) -> Tuple[torch.Tensor, Optional[torch.Tensor]]:
|
| 332 |
+
x = self.front_end(x)
|
| 333 |
+
target_length_in_patches = self.target_length // 4
|
| 334 |
+
x = x.unsqueeze(1)
|
| 335 |
+
x = torch.permute(x, (0, 2, 1, 3))
|
| 336 |
+
x = self.init_bn(x)
|
| 337 |
+
x = torch.permute(x, (0, 2, 1, 3))
|
| 338 |
+
|
| 339 |
+
x = self.patch_embed(x)
|
| 340 |
+
t = x.shape[-1]
|
| 341 |
+
|
| 342 |
+
input_splits = x.split(target_length_in_patches, dim=-1)
|
| 343 |
+
|
| 344 |
+
if x_length is not None:
|
| 345 |
+
assert len(x_length) == len(x), (
|
| 346 |
+
"batchsizes of input x and x_length need to be same"
|
| 347 |
+
)
|
| 348 |
+
assert x_length.ndim == 1, "Lengths are of size (B,)"
|
| 349 |
+
scaled_lengths = (x_length / (self.hop_length * 4)).long()
|
| 350 |
+
mask = self._to_mask(max_length=t, lengths=scaled_lengths)
|
| 351 |
+
split_masks = mask.split(target_length_in_patches, dim=-1)
|
| 352 |
+
else:
|
| 353 |
+
mask = None
|
| 354 |
+
split_masks = [None] * len(input_splits)
|
| 355 |
+
|
| 356 |
+
outputs = []
|
| 357 |
+
|
| 358 |
+
for split_x, split_mask in zip(input_splits, split_masks):
|
| 359 |
+
forward_kwargs = {}
|
| 360 |
+
forward_kwargs["mask"] = split_mask
|
| 361 |
+
split_x = self.forward_features(split_x, **forward_kwargs)
|
| 362 |
+
outputs.append(split_x)
|
| 363 |
+
x = torch.cat(outputs, dim=1)
|
| 364 |
+
return x, mask
|
| 365 |
+
|
| 366 |
+
|
| 367 |
+
class AudioProjectorSubsample(nn.Module):
|
| 368 |
+
def __init__(
|
| 369 |
+
self,
|
| 370 |
+
in_dim: int,
|
| 371 |
+
out_dim: int,
|
| 372 |
+
downsample_rate=5,
|
| 373 |
+
dtype: Optional[torch.dtype] = None,
|
| 374 |
+
):
|
| 375 |
+
super().__init__()
|
| 376 |
+
self.k = downsample_rate
|
| 377 |
+
self.net = nn.Sequential(
|
| 378 |
+
nn.Linear(in_dim * self.k, out_dim, dtype=dtype),
|
| 379 |
+
nn.GELU(),
|
| 380 |
+
nn.Linear(out_dim, out_dim, dtype=dtype),
|
| 381 |
+
)
|
| 382 |
+
|
| 383 |
+
def forward(self, x, mask=None):
|
| 384 |
+
batch_size, seq_len, dim = x.shape
|
| 385 |
+
num_frames_to_discard = seq_len % self.k
|
| 386 |
+
if num_frames_to_discard > 0:
|
| 387 |
+
x = x[:, :-num_frames_to_discard, :]
|
| 388 |
+
if mask is not None:
|
| 389 |
+
mask = mask[:, :-num_frames_to_discard]
|
| 390 |
+
if mask is None:
|
| 391 |
+
mask = torch.ones(x.shape[:-1], dtype=torch.long, device=x.device)
|
| 392 |
+
x = x.reshape(
|
| 393 |
+
batch_size, -1, self.k * dim
|
| 394 |
+
) # rearrange(x, "b (s k) d -> b s (k d)", k=self.k)
|
| 395 |
+
x = self.net(x)
|
| 396 |
+
mask = mask.reshape(
|
| 397 |
+
batch_size, -1, self.k
|
| 398 |
+
) # rearrange(mask, "b (s k) -> b s k", k=self.k)
|
| 399 |
+
mask = mask.any(dim=-1).long()
|
| 400 |
+
return x, mask
|
| 401 |
+
|
| 402 |
+
|
| 403 |
+
@dataclass
|
| 404 |
+
class Qwen25OmniTextModelOutput(ModelOutput):
|
| 405 |
+
loss: Optional[torch.FloatTensor] = None
|
| 406 |
+
logits: Optional[torch.FloatTensor] = None
|
| 407 |
+
past_key_values: Optional[Cache] = None
|
| 408 |
+
hidden_states: Optional[Tuple[torch.FloatTensor, ...]] = None
|
| 409 |
+
attentions: Optional[Tuple[torch.FloatTensor, ...]] = None
|
| 410 |
+
|
| 411 |
+
|
| 412 |
+
class Qwen25OmniThinkerTextOnlyDecoder(PreTrainedModel, GenerationMixin):
|
| 413 |
+
config_class = Qwen2_5OmniTextConfig
|
| 414 |
+
_supports_flash_attn_2 = True
|
| 415 |
+
_supports_sdpa = True
|
| 416 |
+
_supports_cache_class = True
|
| 417 |
+
_supports_static_cache = True
|
| 418 |
+
|
| 419 |
+
def __init__(self, config: Qwen2_5OmniTextConfig):
|
| 420 |
+
super().__init__(config)
|
| 421 |
+
self.model = Qwen2_5OmniThinkerTextModel._from_config(config)
|
| 422 |
+
self.lm_head = nn.Linear(
|
| 423 |
+
config.hidden_size,
|
| 424 |
+
config.vocab_size,
|
| 425 |
+
bias=False,
|
| 426 |
+
)
|
| 427 |
+
self.post_init()
|
| 428 |
+
|
| 429 |
+
@can_return_tuple
|
| 430 |
+
def forward(
|
| 431 |
+
self,
|
| 432 |
+
input_ids: Optional[torch.LongTensor] = None,
|
| 433 |
+
attention_mask: Optional[torch.Tensor] = None,
|
| 434 |
+
position_ids: Optional[torch.LongTensor] = None,
|
| 435 |
+
past_key_values: Optional[List[torch.FloatTensor]] = None,
|
| 436 |
+
inputs_embeds: Optional[torch.FloatTensor] = None,
|
| 437 |
+
use_cache: Optional[bool] = None,
|
| 438 |
+
output_attentions: Optional[bool] = None,
|
| 439 |
+
output_hidden_states: Optional[bool] = None,
|
| 440 |
+
cache_position: Optional[torch.LongTensor] = None,
|
| 441 |
+
labels: Optional[torch.Tensor] = None,
|
| 442 |
+
**kwargs,
|
| 443 |
+
) -> Union[Tuple, Qwen25OmniTextModelOutput]:
|
| 444 |
+
if attention_mask is not None and position_ids is None:
|
| 445 |
+
position_ids = (
|
| 446 |
+
attention_mask.long()
|
| 447 |
+
.cumsum(dim=-1)
|
| 448 |
+
.masked_fill_(attention_mask == 0, 1)
|
| 449 |
+
- 1
|
| 450 |
+
)
|
| 451 |
+
|
| 452 |
+
outputs: BaseModelOutputWithPast = self.model(
|
| 453 |
+
input_ids=input_ids,
|
| 454 |
+
attention_mask=attention_mask,
|
| 455 |
+
position_ids=position_ids,
|
| 456 |
+
past_key_values=past_key_values,
|
| 457 |
+
inputs_embeds=inputs_embeds,
|
| 458 |
+
use_cache=use_cache,
|
| 459 |
+
output_attentions=output_attentions,
|
| 460 |
+
output_hidden_states=output_hidden_states,
|
| 461 |
+
cache_position=cache_position,
|
| 462 |
+
return_dict=True,
|
| 463 |
+
)
|
| 464 |
+
hidden_states = outputs.last_hidden_state
|
| 465 |
+
logits = self.lm_head(hidden_states)
|
| 466 |
+
|
| 467 |
+
loss = (
|
| 468 |
+
self.loss_function(
|
| 469 |
+
logits=logits,
|
| 470 |
+
labels=labels,
|
| 471 |
+
vocab_size=self.config.vocab_size,
|
| 472 |
+
**kwargs,
|
| 473 |
+
)
|
| 474 |
+
if labels is not None
|
| 475 |
+
else None
|
| 476 |
+
)
|
| 477 |
+
|
| 478 |
+
return Qwen25OmniTextModelOutput(
|
| 479 |
+
loss=loss,
|
| 480 |
+
logits=logits,
|
| 481 |
+
past_key_values=outputs.past_key_values,
|
| 482 |
+
hidden_states=outputs.hidden_states,
|
| 483 |
+
attentions=outputs.attentions,
|
| 484 |
+
)
|
| 485 |
+
|
| 486 |
+
|
| 487 |
+
class MiDashengLMModel(PreTrainedModel):
|
| 488 |
+
config_class = MiDashengLMConfig
|
| 489 |
+
_supports_flash_attn_2 = True
|
| 490 |
+
_supports_sdpa = True
|
| 491 |
+
_supports_cache_class = True
|
| 492 |
+
_supports_static_cache = True
|
| 493 |
+
supports_gradient_checkpointing = True
|
| 494 |
+
|
| 495 |
+
def __init__(self, config: MiDashengLMConfig):
|
| 496 |
+
super().__init__(config)
|
| 497 |
+
|
| 498 |
+
self.audio_token_id = config.audio_token_id
|
| 499 |
+
|
| 500 |
+
self.audio_encoder = DashengAudioTransformer._from_config(
|
| 501 |
+
config.audio_encoder_config,
|
| 502 |
+
)
|
| 503 |
+
self.audio_projector = AudioProjectorSubsample(
|
| 504 |
+
self.audio_encoder.embed_dim,
|
| 505 |
+
config.text_config.hidden_size,
|
| 506 |
+
config.subsample_factor,
|
| 507 |
+
)
|
| 508 |
+
self.decoder = Qwen25OmniThinkerTextOnlyDecoder._from_config(
|
| 509 |
+
config.text_config,
|
| 510 |
+
attn_implementation=config._attn_implementation,
|
| 511 |
+
)
|
| 512 |
+
|
| 513 |
+
self.post_init()
|
| 514 |
+
|
| 515 |
+
def get_input_embeddings(self):
|
| 516 |
+
return self.decoder.model.embed_tokens
|
| 517 |
+
|
| 518 |
+
def get_output_embeddings(self):
|
| 519 |
+
return self.decoder.lm_head
|
| 520 |
+
|
| 521 |
+
def _forward_audio_encoder(
|
| 522 |
+
self,
|
| 523 |
+
audios: torch.Tensor,
|
| 524 |
+
audio_length: Optional[Iterable[int]],
|
| 525 |
+
) -> torch.Tensor:
|
| 526 |
+
encoder_out, encoder_atts = self.audio_encoder(audios, audio_length)
|
| 527 |
+
|
| 528 |
+
# audio projector
|
| 529 |
+
encoder_out, encoder_atts = self.audio_projector(encoder_out, encoder_atts)
|
| 530 |
+
|
| 531 |
+
return encoder_out
|
| 532 |
+
|
| 533 |
+
def _prepare_inputs_embeds(
|
| 534 |
+
self,
|
| 535 |
+
input_ids: Optional[torch.Tensor],
|
| 536 |
+
input_values: Optional[torch.Tensor],
|
| 537 |
+
inputs_embeds: Optional[torch.Tensor],
|
| 538 |
+
audio_length: Optional[Iterable[int]] = None,
|
| 539 |
+
) -> torch.Tensor:
|
| 540 |
+
if input_ids is not None:
|
| 541 |
+
if inputs_embeds is not None:
|
| 542 |
+
raise ValueError(
|
| 543 |
+
"Both `inputs_embeds` and `input_ids` are passed. Please pass only one of them."
|
| 544 |
+
)
|
| 545 |
+
inputs_embeds = cast(
|
| 546 |
+
torch.Tensor, self.decoder.model.embed_tokens(input_ids)
|
| 547 |
+
)
|
| 548 |
+
|
| 549 |
+
if input_values is not None:
|
| 550 |
+
if self.audio_token_id is None:
|
| 551 |
+
raise ValueError(
|
| 552 |
+
"Audio input is provided, but `audio_token_id` is not configured."
|
| 553 |
+
)
|
| 554 |
+
|
| 555 |
+
audio_embeddings = self._forward_audio_encoder(
|
| 556 |
+
input_values,
|
| 557 |
+
audio_length=audio_length,
|
| 558 |
+
).to(inputs_embeds.dtype)
|
| 559 |
+
|
| 560 |
+
audio_mask = (input_ids == self.audio_token_id).flatten()
|
| 561 |
+
diff = torch.diff(
|
| 562 |
+
audio_mask.long(),
|
| 563 |
+
prepend=torch.zeros(
|
| 564 |
+
(1,),
|
| 565 |
+
dtype=torch.long,
|
| 566 |
+
device=audio_mask.device,
|
| 567 |
+
),
|
| 568 |
+
)
|
| 569 |
+
audio_span_starts = (diff == 1).nonzero()
|
| 570 |
+
audio_span_ends = (diff == -1).nonzero()
|
| 571 |
+
|
| 572 |
+
embeds_view = inputs_embeds.view(-1, inputs_embeds.shape[-1])
|
| 573 |
+
for span_start, span_end, audio in zip(
|
| 574 |
+
audio_span_starts,
|
| 575 |
+
audio_span_ends,
|
| 576 |
+
audio_embeddings,
|
| 577 |
+
strict=True,
|
| 578 |
+
):
|
| 579 |
+
embeds_view[span_start:span_end] = audio[: span_end - span_start]
|
| 580 |
+
else:
|
| 581 |
+
if inputs_embeds is None:
|
| 582 |
+
raise ValueError(
|
| 583 |
+
"Either `input_ids` or `inputs_embeds` must be passed."
|
| 584 |
+
)
|
| 585 |
+
if input_values is not None:
|
| 586 |
+
raise ValueError(
|
| 587 |
+
"Cannot pass `input_values` when `inputs_embeds` is provided."
|
| 588 |
+
)
|
| 589 |
+
|
| 590 |
+
return inputs_embeds
|
| 591 |
+
|
| 592 |
+
def forward(
|
| 593 |
+
self,
|
| 594 |
+
input_ids: Optional[Tensor] = None,
|
| 595 |
+
input_values: Optional[Tensor] = None,
|
| 596 |
+
inputs_embeds: Optional[Tensor] = None,
|
| 597 |
+
audio_length: Optional[Iterable[int]] = None,
|
| 598 |
+
attention_mask: Optional[Tensor] = None,
|
| 599 |
+
position_ids: Optional[torch.Tensor] = None,
|
| 600 |
+
labels: Optional[torch.Tensor] = None,
|
| 601 |
+
**kwargs: Any,
|
| 602 |
+
):
|
| 603 |
+
inputs_embeds = self._prepare_inputs_embeds(
|
| 604 |
+
input_ids=input_ids,
|
| 605 |
+
input_values=input_values,
|
| 606 |
+
inputs_embeds=inputs_embeds,
|
| 607 |
+
audio_length=audio_length,
|
| 608 |
+
)
|
| 609 |
+
return self.decoder(
|
| 610 |
+
input_ids=None,
|
| 611 |
+
inputs_embeds=inputs_embeds,
|
| 612 |
+
attention_mask=attention_mask,
|
| 613 |
+
position_ids=position_ids,
|
| 614 |
+
labels=labels,
|
| 615 |
+
**kwargs,
|
| 616 |
+
)
|
| 617 |
+
|
| 618 |
+
def generate(
|
| 619 |
+
self,
|
| 620 |
+
input_ids: Optional[Tensor] = None,
|
| 621 |
+
input_values: Optional[Tensor] = None,
|
| 622 |
+
inputs_embeds: Optional[Tensor] = None,
|
| 623 |
+
audio_length: Optional[Iterable[int]] = None,
|
| 624 |
+
**kwargs,
|
| 625 |
+
):
|
| 626 |
+
inputs_embeds = self._prepare_inputs_embeds(
|
| 627 |
+
input_ids=input_ids,
|
| 628 |
+
input_values=input_values,
|
| 629 |
+
inputs_embeds=inputs_embeds,
|
| 630 |
+
audio_length=audio_length,
|
| 631 |
+
)
|
| 632 |
+
return self.decoder.generate(
|
| 633 |
+
inputs_embeds=inputs_embeds,
|
| 634 |
+
generation_config=kwargs.pop("generation_config", self.generation_config),
|
| 635 |
+
**kwargs,
|
| 636 |
+
)
|
preprocessor_config.json
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"auto_map": {
|
| 3 |
+
"AutoProcessor": "processing_midashenglm.MiDashengLMProcessor"
|
| 4 |
+
},
|
| 5 |
+
"do_normalize": false,
|
| 6 |
+
"feature_extractor_type": "Wav2Vec2FeatureExtractor",
|
| 7 |
+
"feature_size": 1,
|
| 8 |
+
"padding_side": "right",
|
| 9 |
+
"padding_value": 0.0,
|
| 10 |
+
"processor_class": "MiDashengLMProcessor",
|
| 11 |
+
"return_attention_mask": false,
|
| 12 |
+
"sampling_rate": 16000
|
| 13 |
+
}
|
processing_midashenglm.py
ADDED
|
@@ -0,0 +1,277 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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| 6 |
+
from transformers.feature_extraction_utils import BatchFeature
|
| 7 |
+
from transformers.processing_utils import ProcessingKwargs, ProcessorMixin
|
| 8 |
+
from typing_extensions import Unpack
|
| 9 |
+
|
| 10 |
+
|
| 11 |
+
class MiDashengLMProcessorKwargs(ProcessingKwargs):
|
| 12 |
+
_defaults = { # type: ignore
|
| 13 |
+
"text_kwargs": {
|
| 14 |
+
"padding": True,
|
| 15 |
+
"padding_side": "left",
|
| 16 |
+
},
|
| 17 |
+
"audio_kwargs": {},
|
| 18 |
+
}
|
| 19 |
+
|
| 20 |
+
|
| 21 |
+
def calculate_mel_frames_dasheng(
|
| 22 |
+
audio_length_samples: int,
|
| 23 |
+
n_fft: int = 512,
|
| 24 |
+
hop_size: int = 160,
|
| 25 |
+
dasheng_subsampling: int = 4,
|
| 26 |
+
center=True,
|
| 27 |
+
model_subsampling: int = 5,
|
| 28 |
+
) -> int:
|
| 29 |
+
"""Calculate the number of Mel-spectrogram frames."""
|
| 30 |
+
if center:
|
| 31 |
+
audio_length_samples = audio_length_samples + n_fft
|
| 32 |
+
|
| 33 |
+
return (
|
| 34 |
+
int(1 + ((audio_length_samples - n_fft) / hop_size))
|
| 35 |
+
// dasheng_subsampling
|
| 36 |
+
// model_subsampling
|
| 37 |
+
)
|
| 38 |
+
|
| 39 |
+
|
| 40 |
+
class MiDashengLMProcessor(ProcessorMixin):
|
| 41 |
+
attributes = ["feature_extractor", "tokenizer"]
|
| 42 |
+
valid_kwargs = [
|
| 43 |
+
"chat_template",
|
| 44 |
+
"audio_token",
|
| 45 |
+
"audio_bos_token",
|
| 46 |
+
"audio_eos_token",
|
| 47 |
+
]
|
| 48 |
+
feature_extractor_class = "Wav2Vec2FeatureExtractor"
|
| 49 |
+
tokenizer_class = ("Qwen2Tokenizer", "Qwen2TokenizerFast")
|
| 50 |
+
|
| 51 |
+
def __init__(
|
| 52 |
+
self,
|
| 53 |
+
feature_extractor: Wav2Vec2FeatureExtractor,
|
| 54 |
+
tokenizer: Union[Qwen2Tokenizer, Qwen2TokenizerFast],
|
| 55 |
+
model_subsampling: int = 5,
|
| 56 |
+
chat_template: Optional[Union[str, Dict[str, str]]] = None,
|
| 57 |
+
audio_token: Optional[str] = None,
|
| 58 |
+
audio_bos_token: Optional[str] = None,
|
| 59 |
+
audio_eos_token: Optional[str] = None,
|
| 60 |
+
):
|
| 61 |
+
assert audio_token is not None or hasattr(tokenizer, "audio_token"), (
|
| 62 |
+
"Either `audio_token` must be provided or tokenizer must have `audio_token` attribute."
|
| 63 |
+
)
|
| 64 |
+
assert audio_bos_token is not None or hasattr(tokenizer, "audio_bos_token"), (
|
| 65 |
+
"Either `audio_bos_token` must be provided or tokenizer must have `audio_bos_token` attribute."
|
| 66 |
+
)
|
| 67 |
+
assert audio_eos_token is not None or hasattr(tokenizer, "audio_eos_token"), (
|
| 68 |
+
"Either `audio_eos_token` must be provided or tokenizer must have `audio_eos_token` attribute."
|
| 69 |
+
)
|
| 70 |
+
assert not feature_extractor.do_normalize, (
|
| 71 |
+
"This model does not use normalization. Please set `do_normalize=False` in the feature extractor."
|
| 72 |
+
)
|
| 73 |
+
|
| 74 |
+
if chat_template is None:
|
| 75 |
+
chat_template = tokenizer.chat_template
|
| 76 |
+
|
| 77 |
+
def get_token(token_name: str) -> str:
|
| 78 |
+
if not hasattr(tokenizer, token_name):
|
| 79 |
+
raise ValueError(
|
| 80 |
+
f"Tokenizer does not have attribute `{token_name}`. "
|
| 81 |
+
"Please provide it as an argument to the processor."
|
| 82 |
+
)
|
| 83 |
+
token = getattr(tokenizer, token_name)
|
| 84 |
+
if not isinstance(token, str):
|
| 85 |
+
raise TypeError(
|
| 86 |
+
f"Expected token {token_name} to be a string, but got {type(token)}."
|
| 87 |
+
)
|
| 88 |
+
return token
|
| 89 |
+
|
| 90 |
+
self.audio_token = audio_token or get_token("audio_token")
|
| 91 |
+
self.audio_bos_token = audio_bos_token or get_token("audio_bos_token")
|
| 92 |
+
self.audio_eos_token = audio_eos_token or get_token("audio_eos_token")
|
| 93 |
+
|
| 94 |
+
self.audio_token_id = cast(
|
| 95 |
+
int, tokenizer.convert_tokens_to_ids(self.audio_token)
|
| 96 |
+
)
|
| 97 |
+
self.model_subsampling = model_subsampling
|
| 98 |
+
self.sampling_rate = feature_extractor.sampling_rate
|
| 99 |
+
|
| 100 |
+
super().__init__(feature_extractor, tokenizer, chat_template=chat_template)
|
| 101 |
+
self.feature_extractor: Wav2Vec2FeatureExtractor
|
| 102 |
+
self.tokenizer: Union[Qwen2Tokenizer, Qwen2TokenizerFast]
|
| 103 |
+
self.chat_template: Optional[Union[str, Dict[str, str]]]
|
| 104 |
+
|
| 105 |
+
def _process_messages_for_chat_template(
|
| 106 |
+
self,
|
| 107 |
+
conversation,
|
| 108 |
+
batch_images,
|
| 109 |
+
batch_videos,
|
| 110 |
+
batch_video_metadata,
|
| 111 |
+
**mm_load_kwargs,
|
| 112 |
+
):
|
| 113 |
+
if (sr := mm_load_kwargs.get("sampling_rate", None)) is not None:
|
| 114 |
+
if sr != self.sampling_rate:
|
| 115 |
+
raise ValueError(
|
| 116 |
+
f"This model is trained with a sampling rate of {self.sampling_rate}, "
|
| 117 |
+
f"but the sampling rate {sr} is used to load audio."
|
| 118 |
+
)
|
| 119 |
+
return super()._process_messages_for_chat_template(
|
| 120 |
+
conversation,
|
| 121 |
+
batch_images,
|
| 122 |
+
batch_videos,
|
| 123 |
+
batch_video_metadata,
|
| 124 |
+
**mm_load_kwargs,
|
| 125 |
+
)
|
| 126 |
+
|
| 127 |
+
@classmethod
|
| 128 |
+
def _validate_audio_sample(
|
| 129 |
+
cls,
|
| 130 |
+
sample: Union[np.ndarray, torch.Tensor],
|
| 131 |
+
) -> np.ndarray:
|
| 132 |
+
if isinstance(sample, torch.Tensor):
|
| 133 |
+
if sample.ndim != 1:
|
| 134 |
+
raise ValueError("Audio tensor must be 1D.")
|
| 135 |
+
return sample.numpy()
|
| 136 |
+
if isinstance(sample, np.ndarray):
|
| 137 |
+
if sample.ndim != 1:
|
| 138 |
+
raise ValueError("Audio array must be 1D.")
|
| 139 |
+
return sample
|
| 140 |
+
if isinstance(sample, str):
|
| 141 |
+
# When passing audio paths through `apply_chat_template`, transformers
|
| 142 |
+
# will attempt to load the audio file, but only succeeds if the path
|
| 143 |
+
# is a valid URL (starting with http:// or https://) or an existing local
|
| 144 |
+
# file. Otherwise, the string is passed as-is. This captures that case and
|
| 145 |
+
# raises an error to inform the user.
|
| 146 |
+
raise TypeError(
|
| 147 |
+
"Expected audio to be a numpy array or torch tensor, but got a string. "
|
| 148 |
+
"If you passed audios through `apply_chat_template`, "
|
| 149 |
+
"make sure the audio paths are valid URLs starting with http:// or https://, "
|
| 150 |
+
"or existing local files."
|
| 151 |
+
)
|
| 152 |
+
raise TypeError(
|
| 153 |
+
f"Expected audio to be a numpy array, torch tensor, or string, but got {type(sample)}."
|
| 154 |
+
)
|
| 155 |
+
|
| 156 |
+
def __call__(
|
| 157 |
+
self,
|
| 158 |
+
text: Optional[List[str]] = None,
|
| 159 |
+
audio: Optional[Union[List[np.ndarray], List[torch.Tensor]]] = None,
|
| 160 |
+
**kwargs: Unpack[MiDashengLMProcessorKwargs],
|
| 161 |
+
) -> BatchFeature:
|
| 162 |
+
if text is None:
|
| 163 |
+
raise ValueError("You need to specify `text` input to process.")
|
| 164 |
+
elif isinstance(text, str):
|
| 165 |
+
text = [text]
|
| 166 |
+
elif not isinstance(text, list) and not isinstance(text[0], str):
|
| 167 |
+
raise ValueError(
|
| 168 |
+
"Invalid input text. Please provide a string, or a list of strings"
|
| 169 |
+
)
|
| 170 |
+
|
| 171 |
+
if (
|
| 172 |
+
kwargs.get("images", None) is not None
|
| 173 |
+
or kwargs.get("videos", None) is not None
|
| 174 |
+
):
|
| 175 |
+
raise ValueError("This model does not support images or videos.")
|
| 176 |
+
|
| 177 |
+
output_kwargs = self._merge_kwargs(
|
| 178 |
+
MiDashengLMProcessorKwargs, # type: ignore # Bad type hint in transformers
|
| 179 |
+
tokenizer_init_kwargs=self.tokenizer.init_kwargs,
|
| 180 |
+
**kwargs,
|
| 181 |
+
)
|
| 182 |
+
|
| 183 |
+
if audio is not None:
|
| 184 |
+
audio = [self._validate_audio_sample(sample) for sample in audio]
|
| 185 |
+
# ensure we have as much audios as audio tokens
|
| 186 |
+
num_audio_tokens = sum(sample.count(self.audio_token) for sample in text)
|
| 187 |
+
num_audios = 1 if type(audio) is np.ndarray else len(audio)
|
| 188 |
+
if num_audio_tokens != num_audios:
|
| 189 |
+
raise ValueError(
|
| 190 |
+
f"Found {num_audio_tokens} {self.audio_token} token{'s' if num_audio_tokens > 1 else ''} in provided text but received {num_audios} audio{'s' if num_audios > 1 else ''}"
|
| 191 |
+
)
|
| 192 |
+
|
| 193 |
+
# Some kwargs should not be changed so we can expand text with audio tokens below
|
| 194 |
+
output_kwargs["audio_kwargs"]["return_attention_mask"] = True
|
| 195 |
+
output_kwargs["audio_kwargs"]["padding"] = True
|
| 196 |
+
output_kwargs["audio_kwargs"]["return_tensors"] = "pt"
|
| 197 |
+
|
| 198 |
+
# + Padding
|
| 199 |
+
audio_inputs = self.feature_extractor(
|
| 200 |
+
audio,
|
| 201 |
+
sampling_rate=self.sampling_rate,
|
| 202 |
+
**output_kwargs["audio_kwargs"],
|
| 203 |
+
)
|
| 204 |
+
|
| 205 |
+
# remove attention mask, dasheng uses lengths
|
| 206 |
+
audio_feature_mask = audio_inputs.pop("attention_mask")
|
| 207 |
+
|
| 208 |
+
expanded_text = []
|
| 209 |
+
audio_lengths = audio_feature_mask.sum(-1).tolist()
|
| 210 |
+
audio_inputs["audio_length"] = torch.tensor(audio_lengths).long()
|
| 211 |
+
|
| 212 |
+
for sample in text:
|
| 213 |
+
replace_str = []
|
| 214 |
+
while self.audio_token in sample:
|
| 215 |
+
audio_length = audio_lengths.pop(0)
|
| 216 |
+
num_audio_tokens = calculate_mel_frames_dasheng(
|
| 217 |
+
audio_length, model_subsampling=self.model_subsampling
|
| 218 |
+
)
|
| 219 |
+
|
| 220 |
+
expanded_audio_token = self.audio_token * num_audio_tokens
|
| 221 |
+
|
| 222 |
+
audio_token_start_idx = sample.find(self.audio_token)
|
| 223 |
+
audio_token_end_idx = audio_token_start_idx + len(self.audio_token)
|
| 224 |
+
|
| 225 |
+
has_bos = (
|
| 226 |
+
sample[
|
| 227 |
+
audio_token_start_idx
|
| 228 |
+
- len(self.audio_bos_token) : audio_token_start_idx
|
| 229 |
+
]
|
| 230 |
+
== self.audio_bos_token
|
| 231 |
+
)
|
| 232 |
+
has_eos = (
|
| 233 |
+
sample[
|
| 234 |
+
audio_token_end_idx : audio_token_end_idx
|
| 235 |
+
+ len(self.audio_eos_token)
|
| 236 |
+
]
|
| 237 |
+
== self.audio_eos_token
|
| 238 |
+
)
|
| 239 |
+
|
| 240 |
+
# Check if this audio token is surrounded by bos/eos tokens
|
| 241 |
+
if not has_bos and not has_eos:
|
| 242 |
+
expanded_audio_token = (
|
| 243 |
+
self.audio_bos_token
|
| 244 |
+
+ expanded_audio_token
|
| 245 |
+
+ self.audio_eos_token
|
| 246 |
+
)
|
| 247 |
+
|
| 248 |
+
replace_str.append(expanded_audio_token)
|
| 249 |
+
sample = sample.replace(self.audio_token, "<placeholder>", 1)
|
| 250 |
+
|
| 251 |
+
while "<placeholder>" in sample:
|
| 252 |
+
sample = sample.replace("<placeholder>", replace_str.pop(0), 1)
|
| 253 |
+
expanded_text.append(sample)
|
| 254 |
+
text = expanded_text
|
| 255 |
+
|
| 256 |
+
return_tensors = output_kwargs["text_kwargs"].pop("return_tensors", "pt")
|
| 257 |
+
inputs = self.tokenizer(text, **output_kwargs["text_kwargs"])
|
| 258 |
+
self._check_special_mm_tokens(
|
| 259 |
+
text,
|
| 260 |
+
BatchFeature(inputs), # type: ignore
|
| 261 |
+
modalities=["audio"],
|
| 262 |
+
)
|
| 263 |
+
|
| 264 |
+
if audio is not None:
|
| 265 |
+
inputs.update(audio_inputs)
|
| 266 |
+
|
| 267 |
+
return BatchFeature(data={**inputs}, tensor_type=return_tensors)
|
| 268 |
+
|
| 269 |
+
@property
|
| 270 |
+
def model_input_names(self):
|
| 271 |
+
tokenizer_input_names = self.tokenizer.model_input_names
|
| 272 |
+
feature_extractor_input_names = self.feature_extractor.model_input_names
|
| 273 |
+
return list(
|
| 274 |
+
dict.fromkeys(
|
| 275 |
+
tokenizer_input_names + feature_extractor_input_names + ["audio_length"]
|
| 276 |
+
)
|
| 277 |
+
)
|
processor_config.json
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"audio_bos_token": "<|audio_bos|>",
|
| 3 |
+
"audio_eos_token": "<|audio_eos|>",
|
| 4 |
+
"audio_token": "<|AUDIO|>",
|
| 5 |
+
"auto_map": {
|
| 6 |
+
"AutoProcessor": "processing_midashenglm.MiDashengLMProcessor"
|
| 7 |
+
},
|
| 8 |
+
"model_subsampling": 5,
|
| 9 |
+
"processor_class": "MiDashengLMProcessor"
|
| 10 |
+
}
|
special_tokens_map.json
ADDED
|
@@ -0,0 +1,144 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
{
|
| 4 |
+
"content": "<|en|>",
|
| 5 |
+
"lstrip": false,
|
| 6 |
+
"normalized": false,
|
| 7 |
+
"rstrip": false,
|
| 8 |
+
"single_word": false
|
| 9 |
+
},
|
| 10 |
+
{
|
| 11 |
+
"content": "<|kr|>",
|
| 12 |
+
"lstrip": false,
|
| 13 |
+
"normalized": false,
|
| 14 |
+
"rstrip": false,
|
| 15 |
+
"single_word": false
|
| 16 |
+
},
|
| 17 |
+
{
|
| 18 |
+
"content": "<|de|>",
|
| 19 |
+
"lstrip": false,
|
| 20 |
+
"normalized": false,
|
| 21 |
+
"rstrip": false,
|
| 22 |
+
"single_word": false
|
| 23 |
+
},
|
| 24 |
+
{
|
| 25 |
+
"content": "<|es|>",
|
| 26 |
+
"lstrip": false,
|
| 27 |
+
"normalized": false,
|
| 28 |
+
"rstrip": false,
|
| 29 |
+
"single_word": false
|
| 30 |
+
},
|
| 31 |
+
{
|
| 32 |
+
"content": "<|fr|>",
|
| 33 |
+
"lstrip": false,
|
| 34 |
+
"normalized": false,
|
| 35 |
+
"rstrip": false,
|
| 36 |
+
"single_word": false
|
| 37 |
+
},
|
| 38 |
+
{
|
| 39 |
+
"content": "<|hi|>",
|
| 40 |
+
"lstrip": false,
|
| 41 |
+
"normalized": false,
|
| 42 |
+
"rstrip": false,
|
| 43 |
+
"single_word": false
|
| 44 |
+
},
|
| 45 |
+
{
|
| 46 |
+
"content": "<|uk|>",
|
| 47 |
+
"lstrip": false,
|
| 48 |
+
"normalized": false,
|
| 49 |
+
"rstrip": false,
|
| 50 |
+
"single_word": false
|
| 51 |
+
},
|
| 52 |
+
{
|
| 53 |
+
"content": "<|th|>",
|
| 54 |
+
"lstrip": false,
|
| 55 |
+
"normalized": false,
|
| 56 |
+
"rstrip": false,
|
| 57 |
+
"single_word": false
|
| 58 |
+
},
|
| 59 |
+
{
|
| 60 |
+
"content": "<|vi|>",
|
| 61 |
+
"lstrip": false,
|
| 62 |
+
"normalized": false,
|
| 63 |
+
"rstrip": false,
|
| 64 |
+
"single_word": false
|
| 65 |
+
},
|
| 66 |
+
{
|
| 67 |
+
"content": "<|nl|>",
|
| 68 |
+
"lstrip": false,
|
| 69 |
+
"normalized": false,
|
| 70 |
+
"rstrip": false,
|
| 71 |
+
"single_word": false
|
| 72 |
+
},
|
| 73 |
+
{
|
| 74 |
+
"content": "<|pt|>",
|
| 75 |
+
"lstrip": false,
|
| 76 |
+
"normalized": false,
|
| 77 |
+
"rstrip": false,
|
| 78 |
+
"single_word": false
|
| 79 |
+
},
|
| 80 |
+
{
|
| 81 |
+
"content": "<|id|>",
|
| 82 |
+
"lstrip": false,
|
| 83 |
+
"normalized": false,
|
| 84 |
+
"rstrip": false,
|
| 85 |
+
"single_word": false
|
| 86 |
+
},
|
| 87 |
+
{
|
| 88 |
+
"content": "<|ru|>",
|
| 89 |
+
"lstrip": false,
|
| 90 |
+
"normalized": false,
|
| 91 |
+
"rstrip": false,
|
| 92 |
+
"single_word": false
|
| 93 |
+
},
|
| 94 |
+
{
|
| 95 |
+
"content": "<|it|>",
|
| 96 |
+
"lstrip": false,
|
| 97 |
+
"normalized": false,
|
| 98 |
+
"rstrip": false,
|
| 99 |
+
"single_word": false
|
| 100 |
+
},
|
| 101 |
+
{
|
| 102 |
+
"content": "<|ar|>",
|
| 103 |
+
"lstrip": false,
|
| 104 |
+
"normalized": false,
|
| 105 |
+
"rstrip": false,
|
| 106 |
+
"single_word": false
|
| 107 |
+
},
|
| 108 |
+
{
|
| 109 |
+
"content": "<|jp|>",
|
| 110 |
+
"lstrip": false,
|
| 111 |
+
"normalized": false,
|
| 112 |
+
"rstrip": false,
|
| 113 |
+
"single_word": false
|
| 114 |
+
},
|
| 115 |
+
{
|
| 116 |
+
"content": "<|unknown|>",
|
| 117 |
+
"lstrip": false,
|
| 118 |
+
"normalized": false,
|
| 119 |
+
"rstrip": false,
|
| 120 |
+
"single_word": false
|
| 121 |
+
}
|
| 122 |
+
],
|
| 123 |
+
"audio_bos_token": "<|audio_bos|>",
|
| 124 |
+
"audio_eos_token": "<|audio_eos|>",
|
| 125 |
+
"audio_token": "<|AUDIO|>",
|
| 126 |
+
"eos_token": {
|
| 127 |
+
"content": "<|im_end|>",
|
| 128 |
+
"lstrip": false,
|
| 129 |
+
"normalized": false,
|
| 130 |
+
"rstrip": false,
|
| 131 |
+
"single_word": false
|
| 132 |
+
},
|
| 133 |
+
"image_token": "<|IMAGE|>",
|
| 134 |
+
"pad_token": {
|
| 135 |
+
"content": "<|endoftext|>",
|
| 136 |
+
"lstrip": false,
|
| 137 |
+
"normalized": false,
|
| 138 |
+
"rstrip": false,
|
| 139 |
+
"single_word": false
|
| 140 |
+
},
|
| 141 |
+
"video_token": "<|VIDEO|>",
|
| 142 |
+
"vision_bos_token": "<|vision_bos|>",
|
| 143 |
+
"vision_eos_token": "<|vision_eos|>"
|
| 144 |
+
}
|
tokenizer.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c40343a9d670f4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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_prefix_space": false,
|
| 3 |
+
"added_tokens_decoder": {
|
| 4 |
+
"151643": {
|
| 5 |
+
"content": "<|endoftext|>",
|
| 6 |
+
"lstrip": false,
|
| 7 |
+
"normalized": false,
|
| 8 |
+
"rstrip": false,
|
| 9 |
+
"single_word": false,
|
| 10 |
+
"special": true
|
| 11 |
+
},
|
| 12 |
+
"151644": {
|
| 13 |
+
"content": "<|im_start|>",
|
| 14 |
+
"lstrip": false,
|
| 15 |
+
"normalized": false,
|
| 16 |
+
"rstrip": false,
|
| 17 |
+
"single_word": false,
|
| 18 |
+
"special": true
|
| 19 |
+
},
|
| 20 |
+
"151645": {
|
| 21 |
+
"content": "<|im_end|>",
|
| 22 |
+
"lstrip": false,
|
| 23 |
+
"normalized": false,
|
| 24 |
+
"rstrip": false,
|
| 25 |
+
"single_word": false,
|
| 26 |
+
"special": true
|
| 27 |
+
},
|
| 28 |
+
"151646": {
|
| 29 |
+
"content": "<|AUDIO|>",
|
| 30 |
+
"lstrip": false,
|
| 31 |
+
"normalized": false,
|
| 32 |
+
"rstrip": false,
|
| 33 |
+
"single_word": false,
|
| 34 |
+
"special": true
|
| 35 |
+
},
|
| 36 |
+
"151647": {
|
| 37 |
+
"content": "<|audio_bos|>",
|
| 38 |
+
"lstrip": false,
|
| 39 |
+
"normalized": false,
|
| 40 |
+
"rstrip": false,
|
| 41 |
+
"single_word": false,
|
| 42 |
+
"special": true
|
| 43 |
+
},
|
| 44 |
+
"151648": {
|
| 45 |
+
"content": "<|audio_eos|>",
|
| 46 |
+
"lstrip": false,
|
| 47 |
+
"normalized": false,
|
| 48 |
+
"rstrip": false,
|
| 49 |
+
"single_word": false,
|
| 50 |
+
"special": true
|
| 51 |
+
},
|
| 52 |
+
"151649": {
|
| 53 |
+
"content": "<|box_end|>",
|
| 54 |
+
"lstrip": false,
|
| 55 |
+
"normalized": false,
|
| 56 |
+
"rstrip": false,
|
| 57 |
+
"single_word": false,
|
| 58 |
+
"special": true
|
| 59 |
+
},
|
| 60 |
+
"151650": {
|
| 61 |
+
"content": "<|quad_start|>",
|
| 62 |
+
"lstrip": false,
|
| 63 |
+
"normalized": false,
|
| 64 |
+
"rstrip": false,
|
| 65 |
+
"single_word": false,
|
| 66 |
+
"special": true
|
| 67 |
+
},
|
| 68 |
+
"151651": {
|
| 69 |
+
"content": "<|quad_end|>",
|
| 70 |
+
"lstrip": false,
|
| 71 |
+
"normalized": false,
|
| 72 |
+
"rstrip": false,
|
| 73 |
+
"single_word": false,
|
| 74 |
+
"special": true
|
| 75 |
+
},
|
| 76 |
+
"151652": {
|
| 77 |
+
"content": "<|vision_bos|>",
|
| 78 |
+
"lstrip": false,
|
| 79 |
+
"normalized": false,
|
| 80 |
+
"rstrip": false,
|
| 81 |
+
"single_word": false,
|
| 82 |
+
"special": true
|
| 83 |
+
},
|
| 84 |
+
"151653": {
|
| 85 |
+
"content": "<|vision_eos|>",
|
| 86 |
+
"lstrip": false,
|
| 87 |
+
"normalized": false,
|
| 88 |
+
"rstrip": false,
|
| 89 |
+
"single_word": false,
|
| 90 |
+
"special": true
|
| 91 |
+
},
|
| 92 |
+
"151654": {
|
| 93 |
+
"content": "<|vision_pad|>",
|
| 94 |
+
"lstrip": false,
|
| 95 |
+
"normalized": false,
|
| 96 |
+
"rstrip": false,
|
| 97 |
+
"single_word": false,
|
| 98 |
+
"special": true
|
| 99 |
+
},
|
| 100 |
+
"151655": {
|
| 101 |
+
"content": "<|IMAGE|>",
|
| 102 |
+
"lstrip": false,
|
| 103 |
+
"normalized": false,
|
| 104 |
+
"rstrip": false,
|
| 105 |
+
"single_word": false,
|
| 106 |
+
"special": true
|
| 107 |
+
},
|
| 108 |
+
"151656": {
|
| 109 |
+
"content": "<|VIDEO|>",
|
| 110 |
+
"lstrip": false,
|
| 111 |
+
"normalized": false,
|
| 112 |
+
"rstrip": false,
|
| 113 |
+
"single_word": false,
|
| 114 |
+
"special": true
|
| 115 |
+
},
|
| 116 |
+
"151657": {
|
| 117 |
+
"content": "<tool_call>",
|
| 118 |
+
"lstrip": false,
|
| 119 |
+
"normalized": false,
|
| 120 |
+
"rstrip": false,
|
| 121 |
+
"single_word": false,
|
| 122 |
+
"special": false
|
| 123 |
+
},
|
| 124 |
+
"151658": {
|
| 125 |
+
"content": "</tool_call>",
|
| 126 |
+
"lstrip": false,
|
| 127 |
+
"normalized": false,
|
| 128 |
+
"rstrip": false,
|
| 129 |
+
"single_word": false,
|
| 130 |
+
"special": false
|
| 131 |
+
},
|
| 132 |
+
"151659": {
|
| 133 |
+
"content": "<|fim_prefix|>",
|
| 134 |
+
"lstrip": false,
|
| 135 |
+
"normalized": false,
|
| 136 |
+
"rstrip": false,
|
| 137 |
+
"single_word": false,
|
| 138 |
+
"special": false
|
| 139 |
+
},
|
| 140 |
+
"151660": {
|
| 141 |
+
"content": "<|fim_middle|>",
|
| 142 |
+
"lstrip": false,
|
| 143 |
+
"normalized": false,
|
| 144 |
+
"rstrip": false,
|
| 145 |
+
"single_word": false,
|
| 146 |
+
"special": false
|
| 147 |
+
},
|
| 148 |
+
"151661": {
|
| 149 |
+
"content": "<|fim_suffix|>",
|
| 150 |
+
"lstrip": false,
|
| 151 |
+
"normalized": false,
|
| 152 |
+
"rstrip": false,
|
| 153 |
+
"single_word": false,
|
| 154 |
+
"special": false
|
| 155 |
+
},
|
| 156 |
+
"151662": {
|
| 157 |
+
"content": "<|fim_pad|>",
|
| 158 |
+
"lstrip": false,
|
| 159 |
+
"normalized": false,
|
| 160 |
+
"rstrip": false,
|
| 161 |
+
"single_word": false,
|
| 162 |
+
"special": false
|
| 163 |
+
},
|
| 164 |
+
"151663": {
|
| 165 |
+
"content": "<|repo_name|>",
|
| 166 |
+
"lstrip": false,
|
| 167 |
+
"normalized": false,
|
| 168 |
+
"rstrip": false,
|
| 169 |
+
"single_word": false,
|
| 170 |
+
"special": false
|
| 171 |
+
},
|
| 172 |
+
"151664": {
|
| 173 |
+
"content": "<|file_sep|>",
|
| 174 |
+
"lstrip": false,
|
| 175 |
+
"normalized": false,
|
| 176 |
+
"rstrip": false,
|
| 177 |
+
"single_word": false,
|
| 178 |
+
"special": false
|
| 179 |
+
},
|
| 180 |
+
"151665": {
|
| 181 |
+
"content": "<|en|>",
|
| 182 |
+
"lstrip": false,
|
| 183 |
+
"normalized": false,
|
| 184 |
+
"rstrip": false,
|
| 185 |
+
"single_word": false,
|
| 186 |
+
"special": true
|
| 187 |
+
},
|
| 188 |
+
"151666": {
|
| 189 |
+
"content": "<|kr|>",
|
| 190 |
+
"lstrip": false,
|
| 191 |
+
"normalized": false,
|
| 192 |
+
"rstrip": false,
|
| 193 |
+
"single_word": false,
|
| 194 |
+
"special": true
|
| 195 |
+
},
|
| 196 |
+
"151667": {
|
| 197 |
+
"content": "<|de|>",
|
| 198 |
+
"lstrip": false,
|
| 199 |
+
"normalized": false,
|
| 200 |
+
"rstrip": false,
|
| 201 |
+
"single_word": false,
|
| 202 |
+
"special": true
|
| 203 |
+
},
|
| 204 |
+
"151668": {
|
| 205 |
+
"content": "<|es|>",
|
| 206 |
+
"lstrip": false,
|
| 207 |
+
"normalized": false,
|
| 208 |
+
"rstrip": false,
|
| 209 |
+
"single_word": false,
|
| 210 |
+
"special": true
|
| 211 |
+
},
|
| 212 |
+
"151669": {
|
| 213 |
+
"content": "<|fr|>",
|
| 214 |
+
"lstrip": false,
|
| 215 |
+
"normalized": false,
|
| 216 |
+
"rstrip": false,
|
| 217 |
+
"single_word": false,
|
| 218 |
+
"special": true
|
| 219 |
+
},
|
| 220 |
+
"151670": {
|
| 221 |
+
"content": "<|hi|>",
|
| 222 |
+
"lstrip": false,
|
| 223 |
+
"normalized": false,
|
| 224 |
+
"rstrip": false,
|
| 225 |
+
"single_word": false,
|
| 226 |
+
"special": true
|
| 227 |
+
},
|
| 228 |
+
"151671": {
|
| 229 |
+
"content": "<|uk|>",
|
| 230 |
+
"lstrip": false,
|
| 231 |
+
"normalized": false,
|
| 232 |
+
"rstrip": false,
|
| 233 |
+
"single_word": false,
|
| 234 |
+
"special": true
|
| 235 |
+
},
|
| 236 |
+
"151672": {
|
| 237 |
+
"content": "<|th|>",
|
| 238 |
+
"lstrip": false,
|
| 239 |
+
"normalized": false,
|
| 240 |
+
"rstrip": false,
|
| 241 |
+
"single_word": false,
|
| 242 |
+
"special": true
|
| 243 |
+
},
|
| 244 |
+
"151673": {
|
| 245 |
+
"content": "<|vi|>",
|
| 246 |
+
"lstrip": false,
|
| 247 |
+
"normalized": false,
|
| 248 |
+
"rstrip": false,
|
| 249 |
+
"single_word": false,
|
| 250 |
+
"special": true
|
| 251 |
+
},
|
| 252 |
+
"151674": {
|
| 253 |
+
"content": "<|nl|>",
|
| 254 |
+
"lstrip": false,
|
| 255 |
+
"normalized": false,
|
| 256 |
+
"rstrip": false,
|
| 257 |
+
"single_word": false,
|
| 258 |
+
"special": true
|
| 259 |
+
},
|
| 260 |
+
"151675": {
|
| 261 |
+
"content": "<|pt|>",
|
| 262 |
+
"lstrip": false,
|
| 263 |
+
"normalized": false,
|
| 264 |
+
"rstrip": false,
|
| 265 |
+
"single_word": false,
|
| 266 |
+
"special": true
|
| 267 |
+
},
|
| 268 |
+
"151676": {
|
| 269 |
+
"content": "<|id|>",
|
| 270 |
+
"lstrip": false,
|
| 271 |
+
"normalized": false,
|
| 272 |
+
"rstrip": false,
|
| 273 |
+
"single_word": false,
|
| 274 |
+
"special": true
|
| 275 |
+
},
|
| 276 |
+
"151677": {
|
| 277 |
+
"content": "<|ru|>",
|
| 278 |
+
"lstrip": false,
|
| 279 |
+
"normalized": false,
|
| 280 |
+
"rstrip": false,
|
| 281 |
+
"single_word": false,
|
| 282 |
+
"special": true
|
| 283 |
+
},
|
| 284 |
+
"151678": {
|
| 285 |
+
"content": "<|it|>",
|
| 286 |
+
"lstrip": false,
|
| 287 |
+
"normalized": false,
|
| 288 |
+
"rstrip": false,
|
| 289 |
+
"single_word": false,
|
| 290 |
+
"special": true
|
| 291 |
+
},
|
| 292 |
+
"151679": {
|
| 293 |
+
"content": "<|ar|>",
|
| 294 |
+
"lstrip": false,
|
| 295 |
+
"normalized": false,
|
| 296 |
+
"rstrip": false,
|
| 297 |
+
"single_word": false,
|
| 298 |
+
"special": true
|
| 299 |
+
},
|
| 300 |
+
"151680": {
|
| 301 |
+
"content": "<|jp|>",
|
| 302 |
+
"lstrip": false,
|
| 303 |
+
"normalized": false,
|
| 304 |
+
"rstrip": false,
|
| 305 |
+
"single_word": false,
|
| 306 |
+
"special": true
|
| 307 |
+
},
|
| 308 |
+
"151681": {
|
| 309 |
+
"content": "<|unknown|>",
|
| 310 |
+
"lstrip": false,
|
| 311 |
+
"normalized": false,
|
| 312 |
+
"rstrip": false,
|
| 313 |
+
"single_word": false,
|
| 314 |
+
"special": true
|
| 315 |
+
}
|
| 316 |
+
},
|
| 317 |
+
"additional_special_tokens": [
|
| 318 |
+
"<|en|>",
|
| 319 |
+
"<|kr|>",
|
| 320 |
+
"<|de|>",
|
| 321 |
+
"<|es|>",
|
| 322 |
+
"<|fr|>",
|
| 323 |
+
"<|hi|>",
|
| 324 |
+
"<|uk|>",
|
| 325 |
+
"<|th|>",
|
| 326 |
+
"<|vi|>",
|
| 327 |
+
"<|nl|>",
|
| 328 |
+
"<|pt|>",
|
| 329 |
+
"<|id|>",
|
| 330 |
+
"<|ru|>",
|
| 331 |
+
"<|it|>",
|
| 332 |
+
"<|ar|>",
|
| 333 |
+
"<|jp|>",
|
| 334 |
+
"<|unknown|>"
|
| 335 |
+
],
|
| 336 |
+
"audio_bos_token": "<|audio_bos|>",
|
| 337 |
+
"audio_eos_token": "<|audio_eos|>",
|
| 338 |
+
"audio_token": "<|AUDIO|>",
|
| 339 |
+
"auto_map": {
|
| 340 |
+
"AutoProcessor": "processing_midashenglm.MiDashengLMProcessor"
|
| 341 |
+
},
|
| 342 |
+
"bos_token": null,
|
| 343 |
+
"clean_up_tokenization_spaces": false,
|
| 344 |
+
"eos_token": "<|im_end|>",
|
| 345 |
+
"errors": "replace",
|
| 346 |
+
"extra_special_tokens": {
|
| 347 |
+
"audio_bos_token": "<|audio_bos|>",
|
| 348 |
+
"audio_eos_token": "<|audio_eos|>",
|
| 349 |
+
"audio_token": "<|AUDIO|>",
|
| 350 |
+
"image_token": "<|IMAGE|>",
|
| 351 |
+
"video_token": "<|VIDEO|>",
|
| 352 |
+
"vision_bos_token": "<|vision_bos|>",
|
| 353 |
+
"vision_eos_token": "<|vision_eos|>"
|
| 354 |
+
},
|
| 355 |
+
"image_token": "<|IMAGE|>",
|
| 356 |
+
"model_max_length": 32768,
|
| 357 |
+
"pad_token": "<|endoftext|>",
|
| 358 |
+
"processor_class": "MiDashengLMProcessor",
|
| 359 |
+
"split_special_tokens": false,
|
| 360 |
+
"tokenizer_class": "Qwen2Tokenizer",
|
| 361 |
+
"unk_token": null,
|
| 362 |
+
"video_token": "<|VIDEO|>",
|
| 363 |
+
"vision_bos_token": "<|vision_bos|>",
|
| 364 |
+
"vision_eos_token": "<|vision_eos|>"
|
| 365 |
+
}
|
vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|