happyme531 commited on
Commit
2ef3e1d
1 Parent(s): 117db54

Upload 20 files

Browse files
.gitattributes CHANGED
@@ -33,3 +33,6 @@ 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
+ audio_encoder.rknn filter=lfs diff=lfs merge=lfs -text
37
+ librkllmrt.so filter=lfs diff=lfs merge=lfs -text
38
+ qwen.rkllm filter=lfs diff=lfs merge=lfs -text
audio_encoder.rknn ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:397ddd3fccf5cca827b765b68ee2623997e7d4b0e36ad1997b366e6ed28eb4d9
3
+ size 1363407727
audio_encoder_convert_rknn.py ADDED
@@ -0,0 +1,87 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env python
2
+ # coding: utf-8
3
+
4
+ import os
5
+ from rknn.api import RKNN
6
+ from sys import exit
7
+ import argparse
8
+ import cv2
9
+ import numpy as np
10
+ os.chdir(os.path.dirname(os.path.abspath(__file__)))
11
+
12
+ seq_lengths = [3000]
13
+ batch_sizes = [1]
14
+ mel_size = 128
15
+
16
+ def convert_encoder():
17
+ rknn = RKNN(verbose=True)
18
+
19
+ ONNX_MODEL=f"audio_encoder.onnx"
20
+ RKNN_MODEL=ONNX_MODEL.replace(".onnx",".rknn")
21
+ DATASET="dataset.txt"
22
+ QUANTIZE=False
23
+ input_shapes = [[[batch_size, mel_size, seq_length], [batch_size, seq_length]] for batch_size in batch_sizes for seq_length in seq_lengths]
24
+ print(input_shapes)
25
+
26
+ # pre-process config
27
+ print('--> Config model')
28
+ rknn.config(quantized_algorithm='normal', quantized_method='channel', target_platform='rk3588', optimization_level=3, dynamic_input=input_shapes) # mean_values=[0.5, 0.5, 0.5], std_values=[0.5, 0.5, 0.5],
29
+ print('done')
30
+
31
+ # Load ONNX model
32
+ print("--> Loading model")
33
+ ret = rknn.load_onnx(
34
+ model=ONNX_MODEL,
35
+ )
36
+
37
+ if ret != 0:
38
+ print('Load model failed!')
39
+ exit(ret)
40
+ print('done')
41
+
42
+ # Build model
43
+ print('--> Building model')
44
+ ret = rknn.build(do_quantization=QUANTIZE, dataset=DATASET, rknn_batch_size=None)
45
+ if ret != 0:
46
+ print('Build model failed!')
47
+ exit(ret)
48
+ print('done')
49
+
50
+ # export
51
+ print('--> Export RKNN model')
52
+ ret = rknn.export_rknn(RKNN_MODEL)
53
+ if ret != 0:
54
+ print('Export RKNN model failed!')
55
+ exit(ret)
56
+ print('done')
57
+ # rknn.init_runtime(target='rk3588')
58
+ # # image embedding
59
+ # img_path = "test.jpg"
60
+
61
+ # normalize_mean = [0.5, 0.5, 0.5]
62
+ # normalize_std = [0.5, 0.5, 0.5]
63
+
64
+ # img = cv2.imread(img_path)
65
+ # img = cv2.resize(img, (448, 448))
66
+ # # img = cv2.cvtColor(img, cv2.COLOR_BGR2RGB)
67
+ # img = img.astype(np.float32)
68
+ # # img = (img - normalize_mean) / normalize_std
69
+ # img = img[np.newaxis, :, :, :]
70
+ # img = img.transpose(0, 3, 1, 2)
71
+ # np.save("img.npy", img)
72
+ # rknn.accuracy_analysis(inputs=["img.npy"], target='rk3588')
73
+ # usage: python convert_rknn.py encoder|all
74
+
75
+ if __name__ == "__main__":
76
+ parser = argparse.ArgumentParser()
77
+ parser.add_argument("model", type=str, help="model to convert", choices=["encoder", "all"], nargs='?')
78
+ args = parser.parse_args()
79
+ if args.model is None:
80
+ args.model = "all"
81
+ if args.model == "encoder":
82
+ convert_encoder()
83
+ elif args.model == "all":
84
+ convert_encoder()
85
+ else:
86
+ print(f"Unknown model: {args.model}")
87
+ exit(1)
audio_encoder_export_onnx.py ADDED
@@ -0,0 +1,88 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import torch
2
+ import torch.nn as nn
3
+
4
+ from transformers import Qwen2AudioForConditionalGeneration
5
+
6
+ class Qwen2AudioEncoderWrapper(nn.Module):
7
+ """包装Qwen2Audio的编码器和映射层用于ONNX导出"""
8
+
9
+ def __init__(self, model):
10
+ super().__init__()
11
+ self.audio_tower = model.audio_tower
12
+ self.projector = model.multi_modal_projector
13
+
14
+ def forward(self, input_features, feature_attention_mask):
15
+ # 计算音频特征长度
16
+ audio_feat_lengths = feature_attention_mask.sum(-1)
17
+ batch_size, _, max_mel_seq_len = input_features.shape
18
+
19
+ # 计算序列长度
20
+ max_seq_len = (max_mel_seq_len - 2) // 2 + 1
21
+ seq_range = torch.arange(0, max_seq_len, device=input_features.device).unsqueeze(0)
22
+ seq_range = seq_range.expand(batch_size, max_seq_len)
23
+
24
+ # 创建attention mask
25
+ lengths_expand = audio_feat_lengths.unsqueeze(1).expand(batch_size, max_seq_len)
26
+ padding_mask = seq_range >= lengths_expand
27
+ audio_attention_mask = padding_mask.view(batch_size, 1, 1, max_seq_len)
28
+ audio_attention_mask = audio_attention_mask.expand(batch_size, 1, max_seq_len, max_seq_len)
29
+ audio_attention_mask = audio_attention_mask.float()
30
+ audio_attention_mask = audio_attention_mask.masked_fill(audio_attention_mask.bool(), float("-inf"))
31
+
32
+ # 获取音频特征
33
+ audio_outputs = self.audio_tower(input_features, attention_mask=audio_attention_mask)
34
+ audio_features = audio_outputs.last_hidden_state
35
+
36
+ # 投影到文本空间
37
+ projected_features = self.projector(audio_features)
38
+
39
+ return projected_features
40
+
41
+ def export_qwen2audio_encoder(model, save_path, input_shape=(1, 80, 3000)):
42
+ """
43
+ 导出Qwen2Audio编码器到ONNX格式
44
+
45
+ Args:
46
+ model: Qwen2AudioForConditionalGeneration模型
47
+ save_path: 保存ONNX模型的路径
48
+ input_shape: 输入音频特征的形状 (batch_size, n_mels, seq_len)
49
+ """
50
+
51
+ wrapper = Qwen2AudioEncoderWrapper(model)
52
+ wrapper.eval()
53
+
54
+ # 准备样例输入
55
+ batch_size, n_mels, seq_len = input_shape
56
+ dummy_input = torch.randn(input_shape)
57
+ dummy_mask = torch.ones((batch_size, seq_len))
58
+
59
+ # 设置动态轴
60
+ dynamic_axes = {
61
+ 'input_features': {0: 'batch_size', 2: 'sequence_length'},
62
+ 'feature_attention_mask': {0: 'batch_size', 1: 'sequence_length'},
63
+ 'output': {0: 'batch_size', 1: 'sequence_length'}
64
+ }
65
+
66
+ # 导出ONNX
67
+ torch.onnx.export(
68
+ wrapper,
69
+ (dummy_input, dummy_mask),
70
+ save_path,
71
+ input_names=['input_features', 'feature_attention_mask'],
72
+ output_names=['output'],
73
+ dynamic_axes=dynamic_axes,
74
+ opset_version=17,
75
+ do_constant_folding=True
76
+ )
77
+
78
+ if __name__ == "__main__":
79
+ # 加载模型
80
+ model = Qwen2AudioForConditionalGeneration.from_pretrained("../Qwen2-Audio-7B-Instruct/")
81
+ model.eval()
82
+
83
+ # 导出ONNX
84
+ export_qwen2audio_encoder(
85
+ model,
86
+ "audio_encoder.onnx",
87
+ input_shape=(1, 128, 3000) # batch_size=1, n_mels=128, seq_len=3000
88
+ )
config.json ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Qwen2ForCausalLM"
4
+ ],
5
+ "bos_token_id": 151643,
6
+ "eos_token_id": 151645,
7
+ "intermediate_size": 11008,
8
+ "max_position_embeddings": 8192,
9
+ "model_type": "qwen2",
10
+ "rope_theta": 10000,
11
+ "rms_norm_eps": 1e-5,
12
+ "sliding_window": 32768,
13
+ "torch_dtype": "bfloat16",
14
+ "use_mrope": false,
15
+ "vocab_size": 156032,
16
+
17
+ "num_hidden_layers": 32,
18
+ "hidden_size": 4096,
19
+ "num_attention_heads": 32
20
+ }
generation_config.json ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "chat_format": "chatml",
3
+ "eos_token_id": [151643,151645],
4
+ "pad_token_id": 151643,
5
+ "do_sample": true,
6
+ "top_k": 20,
7
+ "top_p": 0.5,
8
+ "temperature": 0.7,
9
+ "repetition_penalty": 1.1,
10
+ "transformers_version": "4.38.1"
11
+ }
glass-breaking.wav ADDED
Binary file (774 kB). View file
 
jntm.mp3 ADDED
Binary file (80.6 kB). View file
 
librkllmrt.so ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ac71a21e0fa68df97ab8145a0beae1c561f31d391ea78c12be675b9d34edea85
3
+ size 6226872
merges.txt ADDED
The diff for this file is too large to render. See raw diff
 
model.safetensors.index.json ADDED
@@ -0,0 +1,883 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "metadata": {
3
+ "total_size": 16794189824
4
+ },
5
+ "weight_map": {
6
+ "audio_tower.conv1.bias": "model-renamed-00001-of-00005.safetensors",
7
+ "audio_tower.conv1.weight": "model-renamed-00001-of-00005.safetensors",
8
+ "audio_tower.conv2.bias": "model-renamed-00001-of-00005.safetensors",
9
+ "audio_tower.conv2.weight": "model-renamed-00001-of-00005.safetensors",
10
+ "audio_tower.embed_positions.weight": "model-renamed-00001-of-00005.safetensors",
11
+ "audio_tower.layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
12
+ "audio_tower.layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
13
+ "audio_tower.layers.0.fc1.bias": "model-renamed-00001-of-00005.safetensors",
14
+ "audio_tower.layers.0.fc1.weight": "model-renamed-00001-of-00005.safetensors",
15
+ "audio_tower.layers.0.fc2.bias": "model-renamed-00001-of-00005.safetensors",
16
+ "audio_tower.layers.0.fc2.weight": "model-renamed-00001-of-00005.safetensors",
17
+ "audio_tower.layers.0.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
18
+ "audio_tower.layers.0.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
19
+ "audio_tower.layers.0.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
20
+ "audio_tower.layers.0.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
21
+ "audio_tower.layers.0.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
22
+ "audio_tower.layers.0.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
23
+ "audio_tower.layers.0.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
24
+ "audio_tower.layers.0.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
25
+ "audio_tower.layers.0.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
26
+ "audio_tower.layers.0.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
27
+ "audio_tower.layers.0.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
28
+ "audio_tower.layers.1.fc1.bias": "model-renamed-00001-of-00005.safetensors",
29
+ "audio_tower.layers.1.fc1.weight": "model-renamed-00001-of-00005.safetensors",
30
+ "audio_tower.layers.1.fc2.bias": "model-renamed-00001-of-00005.safetensors",
31
+ "audio_tower.layers.1.fc2.weight": "model-renamed-00001-of-00005.safetensors",
32
+ "audio_tower.layers.1.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
33
+ "audio_tower.layers.1.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
34
+ "audio_tower.layers.1.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
35
+ "audio_tower.layers.1.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
36
+ "audio_tower.layers.1.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
37
+ "audio_tower.layers.1.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
38
+ "audio_tower.layers.1.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
39
+ "audio_tower.layers.1.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
40
+ "audio_tower.layers.1.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
41
+ "audio_tower.layers.1.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
42
+ "audio_tower.layers.1.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
43
+ "audio_tower.layers.10.fc1.bias": "model-renamed-00001-of-00005.safetensors",
44
+ "audio_tower.layers.10.fc1.weight": "model-renamed-00001-of-00005.safetensors",
45
+ "audio_tower.layers.10.fc2.bias": "model-renamed-00001-of-00005.safetensors",
46
+ "audio_tower.layers.10.fc2.weight": "model-renamed-00001-of-00005.safetensors",
47
+ "audio_tower.layers.10.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
48
+ "audio_tower.layers.10.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
49
+ "audio_tower.layers.10.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
50
+ "audio_tower.layers.10.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
51
+ "audio_tower.layers.10.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
52
+ "audio_tower.layers.10.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
53
+ "audio_tower.layers.10.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
54
+ "audio_tower.layers.10.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
55
+ "audio_tower.layers.10.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
56
+ "audio_tower.layers.10.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
57
+ "audio_tower.layers.10.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
58
+ "audio_tower.layers.11.fc1.bias": "model-renamed-00001-of-00005.safetensors",
59
+ "audio_tower.layers.11.fc1.weight": "model-renamed-00001-of-00005.safetensors",
60
+ "audio_tower.layers.11.fc2.bias": "model-renamed-00001-of-00005.safetensors",
61
+ "audio_tower.layers.11.fc2.weight": "model-renamed-00001-of-00005.safetensors",
62
+ "audio_tower.layers.11.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
63
+ "audio_tower.layers.11.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
64
+ "audio_tower.layers.11.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
65
+ "audio_tower.layers.11.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
66
+ "audio_tower.layers.11.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
67
+ "audio_tower.layers.11.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
68
+ "audio_tower.layers.11.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
69
+ "audio_tower.layers.11.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
70
+ "audio_tower.layers.11.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
71
+ "audio_tower.layers.11.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
72
+ "audio_tower.layers.11.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
73
+ "audio_tower.layers.12.fc1.bias": "model-renamed-00001-of-00005.safetensors",
74
+ "audio_tower.layers.12.fc1.weight": "model-renamed-00001-of-00005.safetensors",
75
+ "audio_tower.layers.12.fc2.bias": "model-renamed-00001-of-00005.safetensors",
76
+ "audio_tower.layers.12.fc2.weight": "model-renamed-00001-of-00005.safetensors",
77
+ "audio_tower.layers.12.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
78
+ "audio_tower.layers.12.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
79
+ "audio_tower.layers.12.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
80
+ "audio_tower.layers.12.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
81
+ "audio_tower.layers.12.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
82
+ "audio_tower.layers.12.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
83
+ "audio_tower.layers.12.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
84
+ "audio_tower.layers.12.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
85
+ "audio_tower.layers.12.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
86
+ "audio_tower.layers.12.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
87
+ "audio_tower.layers.12.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
88
+ "audio_tower.layers.13.fc1.bias": "model-renamed-00001-of-00005.safetensors",
89
+ "audio_tower.layers.13.fc1.weight": "model-renamed-00001-of-00005.safetensors",
90
+ "audio_tower.layers.13.fc2.bias": "model-renamed-00001-of-00005.safetensors",
91
+ "audio_tower.layers.13.fc2.weight": "model-renamed-00001-of-00005.safetensors",
92
+ "audio_tower.layers.13.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
93
+ "audio_tower.layers.13.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
94
+ "audio_tower.layers.13.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
95
+ "audio_tower.layers.13.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
96
+ "audio_tower.layers.13.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
97
+ "audio_tower.layers.13.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
98
+ "audio_tower.layers.13.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
99
+ "audio_tower.layers.13.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
100
+ "audio_tower.layers.13.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
101
+ "audio_tower.layers.13.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
102
+ "audio_tower.layers.13.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
103
+ "audio_tower.layers.14.fc1.bias": "model-renamed-00001-of-00005.safetensors",
104
+ "audio_tower.layers.14.fc1.weight": "model-renamed-00001-of-00005.safetensors",
105
+ "audio_tower.layers.14.fc2.bias": "model-renamed-00001-of-00005.safetensors",
106
+ "audio_tower.layers.14.fc2.weight": "model-renamed-00001-of-00005.safetensors",
107
+ "audio_tower.layers.14.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
108
+ "audio_tower.layers.14.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
109
+ "audio_tower.layers.14.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
110
+ "audio_tower.layers.14.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
111
+ "audio_tower.layers.14.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
112
+ "audio_tower.layers.14.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
113
+ "audio_tower.layers.14.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
114
+ "audio_tower.layers.14.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
115
+ "audio_tower.layers.14.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
116
+ "audio_tower.layers.14.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
117
+ "audio_tower.layers.14.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
118
+ "audio_tower.layers.15.fc1.bias": "model-renamed-00001-of-00005.safetensors",
119
+ "audio_tower.layers.15.fc1.weight": "model-renamed-00001-of-00005.safetensors",
120
+ "audio_tower.layers.15.fc2.bias": "model-renamed-00001-of-00005.safetensors",
121
+ "audio_tower.layers.15.fc2.weight": "model-renamed-00001-of-00005.safetensors",
122
+ "audio_tower.layers.15.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
123
+ "audio_tower.layers.15.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
124
+ "audio_tower.layers.15.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
125
+ "audio_tower.layers.15.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
126
+ "audio_tower.layers.15.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
127
+ "audio_tower.layers.15.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
128
+ "audio_tower.layers.15.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
129
+ "audio_tower.layers.15.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
130
+ "audio_tower.layers.15.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
131
+ "audio_tower.layers.15.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
132
+ "audio_tower.layers.15.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
133
+ "audio_tower.layers.16.fc1.bias": "model-renamed-00001-of-00005.safetensors",
134
+ "audio_tower.layers.16.fc1.weight": "model-renamed-00001-of-00005.safetensors",
135
+ "audio_tower.layers.16.fc2.bias": "model-renamed-00001-of-00005.safetensors",
136
+ "audio_tower.layers.16.fc2.weight": "model-renamed-00001-of-00005.safetensors",
137
+ "audio_tower.layers.16.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
138
+ "audio_tower.layers.16.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
139
+ "audio_tower.layers.16.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
140
+ "audio_tower.layers.16.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
141
+ "audio_tower.layers.16.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
142
+ "audio_tower.layers.16.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
143
+ "audio_tower.layers.16.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
144
+ "audio_tower.layers.16.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
145
+ "audio_tower.layers.16.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
146
+ "audio_tower.layers.16.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
147
+ "audio_tower.layers.16.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
148
+ "audio_tower.layers.17.fc1.bias": "model-renamed-00001-of-00005.safetensors",
149
+ "audio_tower.layers.17.fc1.weight": "model-renamed-00001-of-00005.safetensors",
150
+ "audio_tower.layers.17.fc2.bias": "model-renamed-00001-of-00005.safetensors",
151
+ "audio_tower.layers.17.fc2.weight": "model-renamed-00001-of-00005.safetensors",
152
+ "audio_tower.layers.17.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
153
+ "audio_tower.layers.17.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
154
+ "audio_tower.layers.17.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
155
+ "audio_tower.layers.17.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
156
+ "audio_tower.layers.17.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
157
+ "audio_tower.layers.17.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
158
+ "audio_tower.layers.17.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
159
+ "audio_tower.layers.17.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
160
+ "audio_tower.layers.17.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
161
+ "audio_tower.layers.17.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
162
+ "audio_tower.layers.17.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
163
+ "audio_tower.layers.18.fc1.bias": "model-renamed-00001-of-00005.safetensors",
164
+ "audio_tower.layers.18.fc1.weight": "model-renamed-00001-of-00005.safetensors",
165
+ "audio_tower.layers.18.fc2.bias": "model-renamed-00001-of-00005.safetensors",
166
+ "audio_tower.layers.18.fc2.weight": "model-renamed-00001-of-00005.safetensors",
167
+ "audio_tower.layers.18.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
168
+ "audio_tower.layers.18.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
169
+ "audio_tower.layers.18.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
170
+ "audio_tower.layers.18.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
171
+ "audio_tower.layers.18.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
172
+ "audio_tower.layers.18.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
173
+ "audio_tower.layers.18.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
174
+ "audio_tower.layers.18.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
175
+ "audio_tower.layers.18.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
176
+ "audio_tower.layers.18.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
177
+ "audio_tower.layers.18.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
178
+ "audio_tower.layers.19.fc1.bias": "model-renamed-00001-of-00005.safetensors",
179
+ "audio_tower.layers.19.fc1.weight": "model-renamed-00001-of-00005.safetensors",
180
+ "audio_tower.layers.19.fc2.bias": "model-renamed-00001-of-00005.safetensors",
181
+ "audio_tower.layers.19.fc2.weight": "model-renamed-00001-of-00005.safetensors",
182
+ "audio_tower.layers.19.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
183
+ "audio_tower.layers.19.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
184
+ "audio_tower.layers.19.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
185
+ "audio_tower.layers.19.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
186
+ "audio_tower.layers.19.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
187
+ "audio_tower.layers.19.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
188
+ "audio_tower.layers.19.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
189
+ "audio_tower.layers.19.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
190
+ "audio_tower.layers.19.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
191
+ "audio_tower.layers.19.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
192
+ "audio_tower.layers.19.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
193
+ "audio_tower.layers.2.fc1.bias": "model-renamed-00001-of-00005.safetensors",
194
+ "audio_tower.layers.2.fc1.weight": "model-renamed-00001-of-00005.safetensors",
195
+ "audio_tower.layers.2.fc2.bias": "model-renamed-00001-of-00005.safetensors",
196
+ "audio_tower.layers.2.fc2.weight": "model-renamed-00001-of-00005.safetensors",
197
+ "audio_tower.layers.2.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
198
+ "audio_tower.layers.2.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
199
+ "audio_tower.layers.2.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
200
+ "audio_tower.layers.2.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
201
+ "audio_tower.layers.2.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
202
+ "audio_tower.layers.2.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
203
+ "audio_tower.layers.2.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
204
+ "audio_tower.layers.2.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
205
+ "audio_tower.layers.2.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
206
+ "audio_tower.layers.2.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
207
+ "audio_tower.layers.2.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
208
+ "audio_tower.layers.20.fc1.bias": "model-renamed-00001-of-00005.safetensors",
209
+ "audio_tower.layers.20.fc1.weight": "model-renamed-00001-of-00005.safetensors",
210
+ "audio_tower.layers.20.fc2.bias": "model-renamed-00001-of-00005.safetensors",
211
+ "audio_tower.layers.20.fc2.weight": "model-renamed-00001-of-00005.safetensors",
212
+ "audio_tower.layers.20.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
213
+ "audio_tower.layers.20.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
214
+ "audio_tower.layers.20.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
215
+ "audio_tower.layers.20.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
216
+ "audio_tower.layers.20.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
217
+ "audio_tower.layers.20.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
218
+ "audio_tower.layers.20.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
219
+ "audio_tower.layers.20.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
220
+ "audio_tower.layers.20.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
221
+ "audio_tower.layers.20.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
222
+ "audio_tower.layers.20.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
223
+ "audio_tower.layers.21.fc1.bias": "model-renamed-00001-of-00005.safetensors",
224
+ "audio_tower.layers.21.fc1.weight": "model-renamed-00001-of-00005.safetensors",
225
+ "audio_tower.layers.21.fc2.bias": "model-renamed-00001-of-00005.safetensors",
226
+ "audio_tower.layers.21.fc2.weight": "model-renamed-00001-of-00005.safetensors",
227
+ "audio_tower.layers.21.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
228
+ "audio_tower.layers.21.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
229
+ "audio_tower.layers.21.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
230
+ "audio_tower.layers.21.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
231
+ "audio_tower.layers.21.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
232
+ "audio_tower.layers.21.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
233
+ "audio_tower.layers.21.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
234
+ "audio_tower.layers.21.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
235
+ "audio_tower.layers.21.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
236
+ "audio_tower.layers.21.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
237
+ "audio_tower.layers.21.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
238
+ "audio_tower.layers.22.fc1.bias": "model-renamed-00001-of-00005.safetensors",
239
+ "audio_tower.layers.22.fc1.weight": "model-renamed-00001-of-00005.safetensors",
240
+ "audio_tower.layers.22.fc2.bias": "model-renamed-00001-of-00005.safetensors",
241
+ "audio_tower.layers.22.fc2.weight": "model-renamed-00001-of-00005.safetensors",
242
+ "audio_tower.layers.22.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
243
+ "audio_tower.layers.22.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
244
+ "audio_tower.layers.22.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
245
+ "audio_tower.layers.22.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
246
+ "audio_tower.layers.22.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
247
+ "audio_tower.layers.22.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
248
+ "audio_tower.layers.22.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
249
+ "audio_tower.layers.22.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
250
+ "audio_tower.layers.22.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
251
+ "audio_tower.layers.22.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
252
+ "audio_tower.layers.22.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
253
+ "audio_tower.layers.23.fc1.bias": "model-renamed-00001-of-00005.safetensors",
254
+ "audio_tower.layers.23.fc1.weight": "model-renamed-00001-of-00005.safetensors",
255
+ "audio_tower.layers.23.fc2.bias": "model-renamed-00001-of-00005.safetensors",
256
+ "audio_tower.layers.23.fc2.weight": "model-renamed-00001-of-00005.safetensors",
257
+ "audio_tower.layers.23.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
258
+ "audio_tower.layers.23.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
259
+ "audio_tower.layers.23.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
260
+ "audio_tower.layers.23.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
261
+ "audio_tower.layers.23.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
262
+ "audio_tower.layers.23.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
263
+ "audio_tower.layers.23.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
264
+ "audio_tower.layers.23.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
265
+ "audio_tower.layers.23.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
266
+ "audio_tower.layers.23.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
267
+ "audio_tower.layers.23.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
268
+ "audio_tower.layers.24.fc1.bias": "model-renamed-00001-of-00005.safetensors",
269
+ "audio_tower.layers.24.fc1.weight": "model-renamed-00001-of-00005.safetensors",
270
+ "audio_tower.layers.24.fc2.bias": "model-renamed-00001-of-00005.safetensors",
271
+ "audio_tower.layers.24.fc2.weight": "model-renamed-00001-of-00005.safetensors",
272
+ "audio_tower.layers.24.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
273
+ "audio_tower.layers.24.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
274
+ "audio_tower.layers.24.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
275
+ "audio_tower.layers.24.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
276
+ "audio_tower.layers.24.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
277
+ "audio_tower.layers.24.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
278
+ "audio_tower.layers.24.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
279
+ "audio_tower.layers.24.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
280
+ "audio_tower.layers.24.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
281
+ "audio_tower.layers.24.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
282
+ "audio_tower.layers.24.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
283
+ "audio_tower.layers.25.fc1.bias": "model-renamed-00001-of-00005.safetensors",
284
+ "audio_tower.layers.25.fc1.weight": "model-renamed-00001-of-00005.safetensors",
285
+ "audio_tower.layers.25.fc2.bias": "model-renamed-00001-of-00005.safetensors",
286
+ "audio_tower.layers.25.fc2.weight": "model-renamed-00001-of-00005.safetensors",
287
+ "audio_tower.layers.25.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
288
+ "audio_tower.layers.25.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
289
+ "audio_tower.layers.25.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
290
+ "audio_tower.layers.25.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
291
+ "audio_tower.layers.25.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
292
+ "audio_tower.layers.25.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
293
+ "audio_tower.layers.25.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
294
+ "audio_tower.layers.25.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
295
+ "audio_tower.layers.25.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
296
+ "audio_tower.layers.25.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
297
+ "audio_tower.layers.25.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
298
+ "audio_tower.layers.26.fc1.bias": "model-renamed-00001-of-00005.safetensors",
299
+ "audio_tower.layers.26.fc1.weight": "model-renamed-00001-of-00005.safetensors",
300
+ "audio_tower.layers.26.fc2.bias": "model-renamed-00001-of-00005.safetensors",
301
+ "audio_tower.layers.26.fc2.weight": "model-renamed-00001-of-00005.safetensors",
302
+ "audio_tower.layers.26.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
303
+ "audio_tower.layers.26.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
304
+ "audio_tower.layers.26.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
305
+ "audio_tower.layers.26.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
306
+ "audio_tower.layers.26.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
307
+ "audio_tower.layers.26.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
308
+ "audio_tower.layers.26.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
309
+ "audio_tower.layers.26.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
310
+ "audio_tower.layers.26.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
311
+ "audio_tower.layers.26.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
312
+ "audio_tower.layers.26.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
313
+ "audio_tower.layers.27.fc1.bias": "model-renamed-00001-of-00005.safetensors",
314
+ "audio_tower.layers.27.fc1.weight": "model-renamed-00001-of-00005.safetensors",
315
+ "audio_tower.layers.27.fc2.bias": "model-renamed-00001-of-00005.safetensors",
316
+ "audio_tower.layers.27.fc2.weight": "model-renamed-00001-of-00005.safetensors",
317
+ "audio_tower.layers.27.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
318
+ "audio_tower.layers.27.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
319
+ "audio_tower.layers.27.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
320
+ "audio_tower.layers.27.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
321
+ "audio_tower.layers.27.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
322
+ "audio_tower.layers.27.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
323
+ "audio_tower.layers.27.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
324
+ "audio_tower.layers.27.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
325
+ "audio_tower.layers.27.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
326
+ "audio_tower.layers.27.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
327
+ "audio_tower.layers.27.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
328
+ "audio_tower.layers.28.fc1.bias": "model-renamed-00001-of-00005.safetensors",
329
+ "audio_tower.layers.28.fc1.weight": "model-renamed-00001-of-00005.safetensors",
330
+ "audio_tower.layers.28.fc2.bias": "model-renamed-00001-of-00005.safetensors",
331
+ "audio_tower.layers.28.fc2.weight": "model-renamed-00001-of-00005.safetensors",
332
+ "audio_tower.layers.28.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
333
+ "audio_tower.layers.28.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
334
+ "audio_tower.layers.28.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
335
+ "audio_tower.layers.28.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
336
+ "audio_tower.layers.28.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
337
+ "audio_tower.layers.28.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
338
+ "audio_tower.layers.28.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
339
+ "audio_tower.layers.28.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
340
+ "audio_tower.layers.28.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
341
+ "audio_tower.layers.28.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
342
+ "audio_tower.layers.28.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
343
+ "audio_tower.layers.29.fc1.bias": "model-renamed-00001-of-00005.safetensors",
344
+ "audio_tower.layers.29.fc1.weight": "model-renamed-00001-of-00005.safetensors",
345
+ "audio_tower.layers.29.fc2.bias": "model-renamed-00001-of-00005.safetensors",
346
+ "audio_tower.layers.29.fc2.weight": "model-renamed-00001-of-00005.safetensors",
347
+ "audio_tower.layers.29.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
348
+ "audio_tower.layers.29.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
349
+ "audio_tower.layers.29.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
350
+ "audio_tower.layers.29.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
351
+ "audio_tower.layers.29.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
352
+ "audio_tower.layers.29.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
353
+ "audio_tower.layers.29.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
354
+ "audio_tower.layers.29.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
355
+ "audio_tower.layers.29.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
356
+ "audio_tower.layers.29.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
357
+ "audio_tower.layers.29.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
358
+ "audio_tower.layers.3.fc1.bias": "model-renamed-00001-of-00005.safetensors",
359
+ "audio_tower.layers.3.fc1.weight": "model-renamed-00001-of-00005.safetensors",
360
+ "audio_tower.layers.3.fc2.bias": "model-renamed-00001-of-00005.safetensors",
361
+ "audio_tower.layers.3.fc2.weight": "model-renamed-00001-of-00005.safetensors",
362
+ "audio_tower.layers.3.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
363
+ "audio_tower.layers.3.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
364
+ "audio_tower.layers.3.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
365
+ "audio_tower.layers.3.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
366
+ "audio_tower.layers.3.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
367
+ "audio_tower.layers.3.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
368
+ "audio_tower.layers.3.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
369
+ "audio_tower.layers.3.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
370
+ "audio_tower.layers.3.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
371
+ "audio_tower.layers.3.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
372
+ "audio_tower.layers.3.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
373
+ "audio_tower.layers.30.fc1.bias": "model-renamed-00001-of-00005.safetensors",
374
+ "audio_tower.layers.30.fc1.weight": "model-renamed-00001-of-00005.safetensors",
375
+ "audio_tower.layers.30.fc2.bias": "model-renamed-00001-of-00005.safetensors",
376
+ "audio_tower.layers.30.fc2.weight": "model-renamed-00001-of-00005.safetensors",
377
+ "audio_tower.layers.30.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
378
+ "audio_tower.layers.30.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
379
+ "audio_tower.layers.30.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
380
+ "audio_tower.layers.30.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
381
+ "audio_tower.layers.30.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
382
+ "audio_tower.layers.30.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
383
+ "audio_tower.layers.30.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
384
+ "audio_tower.layers.30.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
385
+ "audio_tower.layers.30.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
386
+ "audio_tower.layers.30.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
387
+ "audio_tower.layers.30.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
388
+ "audio_tower.layers.31.fc1.bias": "model-renamed-00001-of-00005.safetensors",
389
+ "audio_tower.layers.31.fc1.weight": "model-renamed-00001-of-00005.safetensors",
390
+ "audio_tower.layers.31.fc2.bias": "model-renamed-00001-of-00005.safetensors",
391
+ "audio_tower.layers.31.fc2.weight": "model-renamed-00001-of-00005.safetensors",
392
+ "audio_tower.layers.31.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
393
+ "audio_tower.layers.31.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
394
+ "audio_tower.layers.31.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
395
+ "audio_tower.layers.31.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
396
+ "audio_tower.layers.31.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
397
+ "audio_tower.layers.31.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
398
+ "audio_tower.layers.31.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
399
+ "audio_tower.layers.31.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
400
+ "audio_tower.layers.31.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
401
+ "audio_tower.layers.31.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
402
+ "audio_tower.layers.31.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
403
+ "audio_tower.layers.4.fc1.bias": "model-renamed-00001-of-00005.safetensors",
404
+ "audio_tower.layers.4.fc1.weight": "model-renamed-00001-of-00005.safetensors",
405
+ "audio_tower.layers.4.fc2.bias": "model-renamed-00001-of-00005.safetensors",
406
+ "audio_tower.layers.4.fc2.weight": "model-renamed-00001-of-00005.safetensors",
407
+ "audio_tower.layers.4.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
408
+ "audio_tower.layers.4.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
409
+ "audio_tower.layers.4.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
410
+ "audio_tower.layers.4.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
411
+ "audio_tower.layers.4.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
412
+ "audio_tower.layers.4.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
413
+ "audio_tower.layers.4.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
414
+ "audio_tower.layers.4.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
415
+ "audio_tower.layers.4.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
416
+ "audio_tower.layers.4.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
417
+ "audio_tower.layers.4.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
418
+ "audio_tower.layers.5.fc1.bias": "model-renamed-00001-of-00005.safetensors",
419
+ "audio_tower.layers.5.fc1.weight": "model-renamed-00001-of-00005.safetensors",
420
+ "audio_tower.layers.5.fc2.bias": "model-renamed-00001-of-00005.safetensors",
421
+ "audio_tower.layers.5.fc2.weight": "model-renamed-00001-of-00005.safetensors",
422
+ "audio_tower.layers.5.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
423
+ "audio_tower.layers.5.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
424
+ "audio_tower.layers.5.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
425
+ "audio_tower.layers.5.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
426
+ "audio_tower.layers.5.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
427
+ "audio_tower.layers.5.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
428
+ "audio_tower.layers.5.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
429
+ "audio_tower.layers.5.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
430
+ "audio_tower.layers.5.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
431
+ "audio_tower.layers.5.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
432
+ "audio_tower.layers.5.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
433
+ "audio_tower.layers.6.fc1.bias": "model-renamed-00001-of-00005.safetensors",
434
+ "audio_tower.layers.6.fc1.weight": "model-renamed-00001-of-00005.safetensors",
435
+ "audio_tower.layers.6.fc2.bias": "model-renamed-00001-of-00005.safetensors",
436
+ "audio_tower.layers.6.fc2.weight": "model-renamed-00001-of-00005.safetensors",
437
+ "audio_tower.layers.6.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
438
+ "audio_tower.layers.6.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
439
+ "audio_tower.layers.6.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
440
+ "audio_tower.layers.6.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
441
+ "audio_tower.layers.6.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
442
+ "audio_tower.layers.6.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
443
+ "audio_tower.layers.6.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
444
+ "audio_tower.layers.6.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
445
+ "audio_tower.layers.6.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
446
+ "audio_tower.layers.6.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
447
+ "audio_tower.layers.6.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
448
+ "audio_tower.layers.7.fc1.bias": "model-renamed-00001-of-00005.safetensors",
449
+ "audio_tower.layers.7.fc1.weight": "model-renamed-00001-of-00005.safetensors",
450
+ "audio_tower.layers.7.fc2.bias": "model-renamed-00001-of-00005.safetensors",
451
+ "audio_tower.layers.7.fc2.weight": "model-renamed-00001-of-00005.safetensors",
452
+ "audio_tower.layers.7.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
453
+ "audio_tower.layers.7.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
454
+ "audio_tower.layers.7.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
455
+ "audio_tower.layers.7.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
456
+ "audio_tower.layers.7.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
457
+ "audio_tower.layers.7.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
458
+ "audio_tower.layers.7.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
459
+ "audio_tower.layers.7.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
460
+ "audio_tower.layers.7.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
461
+ "audio_tower.layers.7.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
462
+ "audio_tower.layers.7.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
463
+ "audio_tower.layers.8.fc1.bias": "model-renamed-00001-of-00005.safetensors",
464
+ "audio_tower.layers.8.fc1.weight": "model-renamed-00001-of-00005.safetensors",
465
+ "audio_tower.layers.8.fc2.bias": "model-renamed-00001-of-00005.safetensors",
466
+ "audio_tower.layers.8.fc2.weight": "model-renamed-00001-of-00005.safetensors",
467
+ "audio_tower.layers.8.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
468
+ "audio_tower.layers.8.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
469
+ "audio_tower.layers.8.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
470
+ "audio_tower.layers.8.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
471
+ "audio_tower.layers.8.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
472
+ "audio_tower.layers.8.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
473
+ "audio_tower.layers.8.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
474
+ "audio_tower.layers.8.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
475
+ "audio_tower.layers.8.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
476
+ "audio_tower.layers.8.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
477
+ "audio_tower.layers.8.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
478
+ "audio_tower.layers.9.fc1.bias": "model-renamed-00001-of-00005.safetensors",
479
+ "audio_tower.layers.9.fc1.weight": "model-renamed-00001-of-00005.safetensors",
480
+ "audio_tower.layers.9.fc2.bias": "model-renamed-00001-of-00005.safetensors",
481
+ "audio_tower.layers.9.fc2.weight": "model-renamed-00001-of-00005.safetensors",
482
+ "audio_tower.layers.9.final_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
483
+ "audio_tower.layers.9.final_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
484
+ "audio_tower.layers.9.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
485
+ "audio_tower.layers.9.self_attn.out_proj.bias": "model-renamed-00001-of-00005.safetensors",
486
+ "audio_tower.layers.9.self_attn.out_proj.weight": "model-renamed-00001-of-00005.safetensors",
487
+ "audio_tower.layers.9.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
488
+ "audio_tower.layers.9.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
489
+ "audio_tower.layers.9.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
490
+ "audio_tower.layers.9.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
491
+ "audio_tower.layers.9.self_attn_layer_norm.bias": "model-renamed-00001-of-00005.safetensors",
492
+ "audio_tower.layers.9.self_attn_layer_norm.weight": "model-renamed-00001-of-00005.safetensors",
493
+ "lm_head.weight": "model-renamed-00005-of-00005.safetensors",
494
+ "model.embed_tokens.weight": "model-renamed-00001-of-00005.safetensors",
495
+ "model.layers.0.input_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
496
+ "model.layers.0.mlp.down_proj.weight": "model-renamed-00001-of-00005.safetensors",
497
+ "model.layers.0.mlp.gate_proj.weight": "model-renamed-00001-of-00005.safetensors",
498
+ "model.layers.0.mlp.up_proj.weight": "model-renamed-00001-of-00005.safetensors",
499
+ "model.layers.0.post_attention_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
500
+ "model.layers.0.self_attn.k_proj.bias": "model-renamed-00001-of-00005.safetensors",
501
+ "model.layers.0.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
502
+ "model.layers.0.self_attn.o_proj.weight": "model-renamed-00001-of-00005.safetensors",
503
+ "model.layers.0.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
504
+ "model.layers.0.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
505
+ "model.layers.0.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
506
+ "model.layers.0.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
507
+ "model.layers.1.input_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
508
+ "model.layers.1.mlp.down_proj.weight": "model-renamed-00001-of-00005.safetensors",
509
+ "model.layers.1.mlp.gate_proj.weight": "model-renamed-00001-of-00005.safetensors",
510
+ "model.layers.1.mlp.up_proj.weight": "model-renamed-00001-of-00005.safetensors",
511
+ "model.layers.1.post_attention_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
512
+ "model.layers.1.self_attn.k_proj.bias": "model-renamed-00001-of-00005.safetensors",
513
+ "model.layers.1.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
514
+ "model.layers.1.self_attn.o_proj.weight": "model-renamed-00001-of-00005.safetensors",
515
+ "model.layers.1.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
516
+ "model.layers.1.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
517
+ "model.layers.1.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
518
+ "model.layers.1.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
519
+ "model.layers.10.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
520
+ "model.layers.10.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
521
+ "model.layers.10.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
522
+ "model.layers.10.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
523
+ "model.layers.10.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
524
+ "model.layers.10.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
525
+ "model.layers.10.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
526
+ "model.layers.10.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
527
+ "model.layers.10.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
528
+ "model.layers.10.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
529
+ "model.layers.10.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
530
+ "model.layers.10.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
531
+ "model.layers.11.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
532
+ "model.layers.11.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
533
+ "model.layers.11.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
534
+ "model.layers.11.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
535
+ "model.layers.11.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
536
+ "model.layers.11.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
537
+ "model.layers.11.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
538
+ "model.layers.11.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
539
+ "model.layers.11.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
540
+ "model.layers.11.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
541
+ "model.layers.11.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
542
+ "model.layers.11.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
543
+ "model.layers.12.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
544
+ "model.layers.12.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
545
+ "model.layers.12.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
546
+ "model.layers.12.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
547
+ "model.layers.12.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
548
+ "model.layers.12.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
549
+ "model.layers.12.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
550
+ "model.layers.12.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
551
+ "model.layers.12.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
552
+ "model.layers.12.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
553
+ "model.layers.12.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
554
+ "model.layers.12.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
555
+ "model.layers.13.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
556
+ "model.layers.13.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
557
+ "model.layers.13.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
558
+ "model.layers.13.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
559
+ "model.layers.13.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
560
+ "model.layers.13.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
561
+ "model.layers.13.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
562
+ "model.layers.13.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
563
+ "model.layers.13.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
564
+ "model.layers.13.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
565
+ "model.layers.13.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
566
+ "model.layers.13.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
567
+ "model.layers.14.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
568
+ "model.layers.14.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
569
+ "model.layers.14.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
570
+ "model.layers.14.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
571
+ "model.layers.14.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
572
+ "model.layers.14.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
573
+ "model.layers.14.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
574
+ "model.layers.14.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
575
+ "model.layers.14.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
576
+ "model.layers.14.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
577
+ "model.layers.14.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
578
+ "model.layers.14.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
579
+ "model.layers.15.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
580
+ "model.layers.15.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
581
+ "model.layers.15.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
582
+ "model.layers.15.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
583
+ "model.layers.15.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
584
+ "model.layers.15.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
585
+ "model.layers.15.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
586
+ "model.layers.15.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
587
+ "model.layers.15.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
588
+ "model.layers.15.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
589
+ "model.layers.15.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
590
+ "model.layers.15.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
591
+ "model.layers.16.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
592
+ "model.layers.16.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
593
+ "model.layers.16.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
594
+ "model.layers.16.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
595
+ "model.layers.16.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
596
+ "model.layers.16.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
597
+ "model.layers.16.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
598
+ "model.layers.16.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
599
+ "model.layers.16.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
600
+ "model.layers.16.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
601
+ "model.layers.16.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
602
+ "model.layers.16.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
603
+ "model.layers.17.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
604
+ "model.layers.17.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
605
+ "model.layers.17.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
606
+ "model.layers.17.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
607
+ "model.layers.17.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
608
+ "model.layers.17.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
609
+ "model.layers.17.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
610
+ "model.layers.17.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
611
+ "model.layers.17.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
612
+ "model.layers.17.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
613
+ "model.layers.17.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
614
+ "model.layers.17.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
615
+ "model.layers.18.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
616
+ "model.layers.18.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
617
+ "model.layers.18.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
618
+ "model.layers.18.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
619
+ "model.layers.18.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
620
+ "model.layers.18.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
621
+ "model.layers.18.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
622
+ "model.layers.18.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
623
+ "model.layers.18.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
624
+ "model.layers.18.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
625
+ "model.layers.18.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
626
+ "model.layers.18.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
627
+ "model.layers.19.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
628
+ "model.layers.19.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
629
+ "model.layers.19.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
630
+ "model.layers.19.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
631
+ "model.layers.19.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
632
+ "model.layers.19.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
633
+ "model.layers.19.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
634
+ "model.layers.19.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
635
+ "model.layers.19.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
636
+ "model.layers.19.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
637
+ "model.layers.19.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
638
+ "model.layers.19.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
639
+ "model.layers.2.input_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
640
+ "model.layers.2.mlp.down_proj.weight": "model-renamed-00001-of-00005.safetensors",
641
+ "model.layers.2.mlp.gate_proj.weight": "model-renamed-00001-of-00005.safetensors",
642
+ "model.layers.2.mlp.up_proj.weight": "model-renamed-00001-of-00005.safetensors",
643
+ "model.layers.2.post_attention_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
644
+ "model.layers.2.self_attn.k_proj.bias": "model-renamed-00001-of-00005.safetensors",
645
+ "model.layers.2.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
646
+ "model.layers.2.self_attn.o_proj.weight": "model-renamed-00001-of-00005.safetensors",
647
+ "model.layers.2.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
648
+ "model.layers.2.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
649
+ "model.layers.2.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
650
+ "model.layers.2.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
651
+ "model.layers.20.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
652
+ "model.layers.20.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
653
+ "model.layers.20.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
654
+ "model.layers.20.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
655
+ "model.layers.20.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
656
+ "model.layers.20.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
657
+ "model.layers.20.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
658
+ "model.layers.20.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
659
+ "model.layers.20.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
660
+ "model.layers.20.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
661
+ "model.layers.20.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
662
+ "model.layers.20.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
663
+ "model.layers.21.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
664
+ "model.layers.21.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
665
+ "model.layers.21.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
666
+ "model.layers.21.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
667
+ "model.layers.21.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
668
+ "model.layers.21.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
669
+ "model.layers.21.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
670
+ "model.layers.21.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
671
+ "model.layers.21.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
672
+ "model.layers.21.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
673
+ "model.layers.21.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
674
+ "model.layers.21.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
675
+ "model.layers.22.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
676
+ "model.layers.22.mlp.down_proj.weight": "model-renamed-00003-of-00005.safetensors",
677
+ "model.layers.22.mlp.gate_proj.weight": "model-renamed-00003-of-00005.safetensors",
678
+ "model.layers.22.mlp.up_proj.weight": "model-renamed-00003-of-00005.safetensors",
679
+ "model.layers.22.post_attention_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
680
+ "model.layers.22.self_attn.k_proj.bias": "model-renamed-00003-of-00005.safetensors",
681
+ "model.layers.22.self_attn.k_proj.weight": "model-renamed-00003-of-00005.safetensors",
682
+ "model.layers.22.self_attn.o_proj.weight": "model-renamed-00003-of-00005.safetensors",
683
+ "model.layers.22.self_attn.q_proj.bias": "model-renamed-00003-of-00005.safetensors",
684
+ "model.layers.22.self_attn.q_proj.weight": "model-renamed-00003-of-00005.safetensors",
685
+ "model.layers.22.self_attn.v_proj.bias": "model-renamed-00003-of-00005.safetensors",
686
+ "model.layers.22.self_attn.v_proj.weight": "model-renamed-00003-of-00005.safetensors",
687
+ "model.layers.23.input_layernorm.weight": "model-renamed-00003-of-00005.safetensors",
688
+ "model.layers.23.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
689
+ "model.layers.23.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
690
+ "model.layers.23.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
691
+ "model.layers.23.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
692
+ "model.layers.23.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
693
+ "model.layers.23.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
694
+ "model.layers.23.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
695
+ "model.layers.23.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
696
+ "model.layers.23.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
697
+ "model.layers.23.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
698
+ "model.layers.23.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
699
+ "model.layers.24.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
700
+ "model.layers.24.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
701
+ "model.layers.24.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
702
+ "model.layers.24.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
703
+ "model.layers.24.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
704
+ "model.layers.24.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
705
+ "model.layers.24.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
706
+ "model.layers.24.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
707
+ "model.layers.24.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
708
+ "model.layers.24.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
709
+ "model.layers.24.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
710
+ "model.layers.24.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
711
+ "model.layers.25.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
712
+ "model.layers.25.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
713
+ "model.layers.25.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
714
+ "model.layers.25.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
715
+ "model.layers.25.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
716
+ "model.layers.25.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
717
+ "model.layers.25.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
718
+ "model.layers.25.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
719
+ "model.layers.25.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
720
+ "model.layers.25.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
721
+ "model.layers.25.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
722
+ "model.layers.25.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
723
+ "model.layers.26.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
724
+ "model.layers.26.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
725
+ "model.layers.26.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
726
+ "model.layers.26.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
727
+ "model.layers.26.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
728
+ "model.layers.26.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
729
+ "model.layers.26.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
730
+ "model.layers.26.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
731
+ "model.layers.26.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
732
+ "model.layers.26.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
733
+ "model.layers.26.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
734
+ "model.layers.26.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
735
+ "model.layers.27.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
736
+ "model.layers.27.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
737
+ "model.layers.27.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
738
+ "model.layers.27.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
739
+ "model.layers.27.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
740
+ "model.layers.27.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
741
+ "model.layers.27.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
742
+ "model.layers.27.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
743
+ "model.layers.27.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
744
+ "model.layers.27.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
745
+ "model.layers.27.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
746
+ "model.layers.27.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
747
+ "model.layers.28.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
748
+ "model.layers.28.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
749
+ "model.layers.28.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
750
+ "model.layers.28.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
751
+ "model.layers.28.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
752
+ "model.layers.28.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
753
+ "model.layers.28.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
754
+ "model.layers.28.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
755
+ "model.layers.28.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
756
+ "model.layers.28.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
757
+ "model.layers.28.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
758
+ "model.layers.28.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
759
+ "model.layers.29.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
760
+ "model.layers.29.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
761
+ "model.layers.29.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
762
+ "model.layers.29.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
763
+ "model.layers.29.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
764
+ "model.layers.29.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
765
+ "model.layers.29.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
766
+ "model.layers.29.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
767
+ "model.layers.29.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
768
+ "model.layers.29.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
769
+ "model.layers.29.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
770
+ "model.layers.29.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
771
+ "model.layers.3.input_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
772
+ "model.layers.3.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
773
+ "model.layers.3.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
774
+ "model.layers.3.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
775
+ "model.layers.3.post_attention_layernorm.weight": "model-renamed-00001-of-00005.safetensors",
776
+ "model.layers.3.self_attn.k_proj.bias": "model-renamed-00001-of-00005.safetensors",
777
+ "model.layers.3.self_attn.k_proj.weight": "model-renamed-00001-of-00005.safetensors",
778
+ "model.layers.3.self_attn.o_proj.weight": "model-renamed-00001-of-00005.safetensors",
779
+ "model.layers.3.self_attn.q_proj.bias": "model-renamed-00001-of-00005.safetensors",
780
+ "model.layers.3.self_attn.q_proj.weight": "model-renamed-00001-of-00005.safetensors",
781
+ "model.layers.3.self_attn.v_proj.bias": "model-renamed-00001-of-00005.safetensors",
782
+ "model.layers.3.self_attn.v_proj.weight": "model-renamed-00001-of-00005.safetensors",
783
+ "model.layers.30.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
784
+ "model.layers.30.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
785
+ "model.layers.30.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
786
+ "model.layers.30.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
787
+ "model.layers.30.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
788
+ "model.layers.30.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
789
+ "model.layers.30.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
790
+ "model.layers.30.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
791
+ "model.layers.30.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
792
+ "model.layers.30.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
793
+ "model.layers.30.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
794
+ "model.layers.30.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
795
+ "model.layers.31.input_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
796
+ "model.layers.31.mlp.down_proj.weight": "model-renamed-00004-of-00005.safetensors",
797
+ "model.layers.31.mlp.gate_proj.weight": "model-renamed-00004-of-00005.safetensors",
798
+ "model.layers.31.mlp.up_proj.weight": "model-renamed-00004-of-00005.safetensors",
799
+ "model.layers.31.post_attention_layernorm.weight": "model-renamed-00004-of-00005.safetensors",
800
+ "model.layers.31.self_attn.k_proj.bias": "model-renamed-00004-of-00005.safetensors",
801
+ "model.layers.31.self_attn.k_proj.weight": "model-renamed-00004-of-00005.safetensors",
802
+ "model.layers.31.self_attn.o_proj.weight": "model-renamed-00004-of-00005.safetensors",
803
+ "model.layers.31.self_attn.q_proj.bias": "model-renamed-00004-of-00005.safetensors",
804
+ "model.layers.31.self_attn.q_proj.weight": "model-renamed-00004-of-00005.safetensors",
805
+ "model.layers.31.self_attn.v_proj.bias": "model-renamed-00004-of-00005.safetensors",
806
+ "model.layers.31.self_attn.v_proj.weight": "model-renamed-00004-of-00005.safetensors",
807
+ "model.layers.4.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
808
+ "model.layers.4.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
809
+ "model.layers.4.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
810
+ "model.layers.4.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
811
+ "model.layers.4.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
812
+ "model.layers.4.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
813
+ "model.layers.4.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
814
+ "model.layers.4.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
815
+ "model.layers.4.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
816
+ "model.layers.4.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
817
+ "model.layers.4.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
818
+ "model.layers.4.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
819
+ "model.layers.5.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
820
+ "model.layers.5.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
821
+ "model.layers.5.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
822
+ "model.layers.5.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
823
+ "model.layers.5.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
824
+ "model.layers.5.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
825
+ "model.layers.5.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
826
+ "model.layers.5.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
827
+ "model.layers.5.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
828
+ "model.layers.5.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
829
+ "model.layers.5.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
830
+ "model.layers.5.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
831
+ "model.layers.6.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
832
+ "model.layers.6.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
833
+ "model.layers.6.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
834
+ "model.layers.6.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
835
+ "model.layers.6.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
836
+ "model.layers.6.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
837
+ "model.layers.6.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
838
+ "model.layers.6.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
839
+ "model.layers.6.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
840
+ "model.layers.6.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
841
+ "model.layers.6.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
842
+ "model.layers.6.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
843
+ "model.layers.7.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
844
+ "model.layers.7.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
845
+ "model.layers.7.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
846
+ "model.layers.7.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
847
+ "model.layers.7.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
848
+ "model.layers.7.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
849
+ "model.layers.7.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
850
+ "model.layers.7.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
851
+ "model.layers.7.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
852
+ "model.layers.7.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
853
+ "model.layers.7.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
854
+ "model.layers.7.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
855
+ "model.layers.8.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
856
+ "model.layers.8.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
857
+ "model.layers.8.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
858
+ "model.layers.8.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
859
+ "model.layers.8.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
860
+ "model.layers.8.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
861
+ "model.layers.8.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
862
+ "model.layers.8.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
863
+ "model.layers.8.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
864
+ "model.layers.8.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
865
+ "model.layers.8.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
866
+ "model.layers.8.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
867
+ "model.layers.9.input_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
868
+ "model.layers.9.mlp.down_proj.weight": "model-renamed-00002-of-00005.safetensors",
869
+ "model.layers.9.mlp.gate_proj.weight": "model-renamed-00002-of-00005.safetensors",
870
+ "model.layers.9.mlp.up_proj.weight": "model-renamed-00002-of-00005.safetensors",
871
+ "model.layers.9.post_attention_layernorm.weight": "model-renamed-00002-of-00005.safetensors",
872
+ "model.layers.9.self_attn.k_proj.bias": "model-renamed-00002-of-00005.safetensors",
873
+ "model.layers.9.self_attn.k_proj.weight": "model-renamed-00002-of-00005.safetensors",
874
+ "model.layers.9.self_attn.o_proj.weight": "model-renamed-00002-of-00005.safetensors",
875
+ "model.layers.9.self_attn.q_proj.bias": "model-renamed-00002-of-00005.safetensors",
876
+ "model.layers.9.self_attn.q_proj.weight": "model-renamed-00002-of-00005.safetensors",
877
+ "model.layers.9.self_attn.v_proj.bias": "model-renamed-00002-of-00005.safetensors",
878
+ "model.layers.9.self_attn.v_proj.weight": "model-renamed-00002-of-00005.safetensors",
879
+ "model.norm.weight": "model-renamed-00004-of-00005.safetensors",
880
+ "multi_modal_projector.linear.bias": "model-renamed-00001-of-00005.safetensors",
881
+ "multi_modal_projector.linear.weight": "model-renamed-00001-of-00005.safetensors"
882
+ }
883
+ }
multiprocess_inference.py ADDED
@@ -0,0 +1,334 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import faulthandler
2
+ faulthandler.enable()
3
+ import os
4
+ import random
5
+ import time
6
+ import signal
7
+ from multiprocessing import Process, Queue, Event
8
+ import numpy as np
9
+ from rkllm_binding import *
10
+ from rknnlite.api.rknn_lite import RKNNLite
11
+ import threading
12
+ import librosa
13
+ from transformers import WhisperFeatureExtractor
14
+
15
+ # 音频编码器进程
16
+ def audio_encoder_process(load_ready_queue, embedding_queue, audio_path_queue, start_event):
17
+
18
+ AUDIO_ENCODER_PATH = "audio_encoder.rknn"
19
+
20
+ # 初始化音频编码器
21
+ audio_encoder = RKNNLite(verbose=False)
22
+ model_size = os.path.getsize(AUDIO_ENCODER_PATH)
23
+ print(f"Start loading audio encoder model (size: {model_size / 1024 / 1024:.2f} MB)")
24
+ start_time = time.time()
25
+ audio_encoder.load_rknn(AUDIO_ENCODER_PATH)
26
+ end_time = time.time()
27
+ print(f"Audio encoder loaded in {end_time - start_time:.2f} seconds")
28
+ audio_encoder.init_runtime()
29
+
30
+ # 初始化Whisper特征提取器
31
+ feature_extractor = WhisperFeatureExtractor.from_pretrained(".")
32
+
33
+ # 通知主进程加载完成
34
+ load_ready_queue.put("audio_ready")
35
+
36
+ # 等待开始信号
37
+ start_event.wait()
38
+
39
+ def process_audio(audio_path, audio_encoder, feature_extractor):
40
+ try:
41
+ print("Start audio inference...")
42
+ audio, _ = librosa.load(audio_path, sr=feature_extractor.sampling_rate)
43
+ feature_extractor_output = feature_extractor(
44
+ audio,
45
+ sampling_rate=feature_extractor.sampling_rate,
46
+ return_attention_mask=True,
47
+ padding="max_length"
48
+ )
49
+
50
+ start_time = time.time()
51
+ audio_embeddings = audio_encoder.inference(inputs=[
52
+ feature_extractor_output.input_features.astype(np.float32),
53
+ feature_extractor_output.attention_mask.astype(np.float32)
54
+ ], data_format="nhwc")[0].astype(np.float32)
55
+ end_time = time.time()
56
+ print(f"Audio encoder inference time: {end_time - start_time:.2f} seconds")
57
+
58
+ effective_length = feature_extractor_output.attention_mask.sum(-1)[0]
59
+ effective_length = (effective_length - 1) // 2 + 1
60
+ output_lengths = (effective_length - 2) // 2 + 1
61
+ audio_embeddings = audio_embeddings[:, :output_lengths]
62
+ print(audio_embeddings.shape)
63
+ return audio_embeddings
64
+ except Exception as e:
65
+ print(f"Error processing audio: {e}")
66
+ return None
67
+
68
+ while True:
69
+ audio_path = audio_path_queue.get()
70
+ if audio_path == "STOP":
71
+ break
72
+ embeddings = process_audio(audio_path, audio_encoder, feature_extractor)
73
+ if embeddings is not None:
74
+ embedding_queue.put(embeddings)
75
+ else:
76
+ embedding_queue.put("ERROR")
77
+
78
+ # LLM进程
79
+ def llm_process(load_ready_queue, embedding_queue, prompt_queue, inference_done_queue, start_event):
80
+
81
+
82
+ MODEL_PATH = "/home/firefly/qwen.rkllm"
83
+ handle = None
84
+ import locale
85
+
86
+ # 获取系统语言
87
+ system_lang = locale.getdefaultlocale()[0]
88
+ is_chinese = system_lang and system_lang.startswith('zh')
89
+ # is_chinese = False
90
+
91
+ # 添加进度提示信息列表
92
+ progress_messages_zh = [
93
+ "🚀 启动量子加速引擎...",
94
+ "🧠 神经网络正在苏醒...",
95
+ "🔄 并行宇宙计算进行中...",
96
+ "🌟 正在注入能量矩阵...",
97
+ "🔥 CPU已经到达工作温度,全力运转中...",
98
+ "🎯 特征向量正在跳跃式生长...",
99
+ "🎭 多头注意力机制开始营业...",
100
+ "💨 散热风扇已经进入超音速状态...",
101
+ "📚 语义解析器正在啃食数据...",
102
+ "🔍 上下文关联分析师正在加班...",
103
+ "🎨 视觉特征正在调色盘中混合...",
104
+ "🤝 跨模态对齐正在相亲相爱中...",
105
+ "⚡ 深度特征提取器已经深入地心...",
106
+ "🧪 神经网络正在炼丹中...",
107
+ "🎲 张量计算已经进入量子态...",
108
+ "📦 模型参数正在装箱搬运...",
109
+ "⚖️ 权重矩阵正在天平上找平衡...",
110
+ "🗺 语义向量正在绘制航海图...",
111
+ "🎭 注意力头们正在开会讨论...",
112
+ "🏗 残差模块正在搭建天梯...",
113
+ "🌈 激活函数正在调制彩虹...",
114
+ "🎮 张量核心正在玩魔方...",
115
+ "🎪 循环神经网络正在马戏团表演...",
116
+ "🎨 特征图正在画饼充饥...",
117
+ "🔮 模型正在占卜未来...",
118
+ "🎯 优化器正在进行火箭轨道计算...",
119
+ "🎪 批归一化正在杂技表演...",
120
+ "🎭 Dropout正在玩捉迷藏...",
121
+ "🌪 梯度正在形成龙卷风...",
122
+ "🎢 反向传播正在过山车..."
123
+ ]
124
+
125
+ progress_messages_en = [
126
+ "Loading...",
127
+ "Extracting...",
128
+ "Image fusion in progress...",
129
+ "Matrix multiplication...",
130
+ "Chip heating up...",
131
+ "Feature vector calculation...",
132
+ "Attention mechanism processing...",
133
+ "Fan speed increasing...",
134
+ "Semantic parsing...",
135
+ "Context analysis...",
136
+ "Visual feature encoding...",
137
+ "Cross-modal alignment...",
138
+ "Deep feature extraction...",
139
+ "Neural network inference...",
140
+ "Tensor operations...",
141
+ "Loading model parameters...",
142
+ "Weight matrix calculation...",
143
+ "Semantic vector mapping...",
144
+ "Multi-head attention...",
145
+ "Residual connection..."
146
+ ]
147
+
148
+ # 根据语言选择提示信息
149
+ progress_messages = progress_messages_zh if is_chinese else progress_messages_en
150
+
151
+ # 添加进度提示控制事件
152
+ progress_stop_event = threading.Event()
153
+
154
+ # 进度提示线程函数
155
+ def show_progress():
156
+ while not progress_stop_event.is_set():
157
+ for msg in progress_messages:
158
+ if progress_stop_event.is_set():
159
+ break
160
+ print(f"{msg}", flush=True)
161
+ time.sleep(random.uniform(0.1, 0.4))
162
+
163
+ def signal_handler(signal, frame):
164
+ print("Ctrl-C pressed, exiting...")
165
+ global handle
166
+ if handle:
167
+ abort(handle)
168
+ destroy(handle)
169
+ exit(0)
170
+
171
+ signal.signal(signal.SIGINT, signal_handler)
172
+ os.environ["RKLLM_LOG_LEVEL"] = "1"
173
+
174
+ inference_count = 0
175
+ inference_start_time = 0
176
+ def result_callback(result, userdata, state):
177
+ nonlocal inference_start_time, inference_count
178
+ if state == LLMCallState.RKLLM_RUN_NORMAL:
179
+ if inference_count == 0:
180
+ progress_stop_event.set() # 停止进度提示
181
+ first_token_time = time.time()
182
+ print("🎉 完成!")
183
+ print(f"\nTime to first token: {first_token_time - inference_start_time:.2f} seconds")
184
+ inference_count += 1
185
+ print(result.contents.text.decode(), end="", flush=True)
186
+ elif state == LLMCallState.RKLLM_RUN_FINISH:
187
+ print("\n\n(finished)")
188
+ inference_done_queue.put("DONE")
189
+ elif state == LLMCallState.RKLLM_RUN_ERROR:
190
+ print("\nError occurred during LLM call")
191
+ inference_done_queue.put("ERROR")
192
+
193
+ # 初始化LLM
194
+ param = create_default_param()
195
+ param.model_path = MODEL_PATH.encode()
196
+ param.img_start = "<|audio_bos|>".encode()
197
+ param.img_end = "<|audio_eos|>".encode()
198
+ param.img_content = "<|AUDIO|>".encode()
199
+ param.max_context_len = 768
200
+ param.max_new_tokens = 256
201
+ extend_param = RKLLMExtendParam()
202
+ extend_param.base_domain_id = 1
203
+ param.extend_param = extend_param
204
+
205
+ model_size = os.path.getsize(MODEL_PATH)
206
+ print(f"Start loading language model (size: {model_size / 1024 / 1024:.2f} MB)")
207
+ start_time = time.time()
208
+ handle = init(param, result_callback)
209
+ end_time = time.time()
210
+ print(f"Language model loaded in {end_time - start_time:.2f} seconds")
211
+
212
+ # 通知主进程加载完成
213
+ load_ready_queue.put("llm_ready")
214
+
215
+ # 创建推理参数
216
+ infer_param = RKLLMInferParam()
217
+ infer_param.mode = RKLLMInferMode.RKLLM_INFER_GENERATE.value
218
+
219
+ while True:
220
+ prompt = prompt_queue.get()
221
+ print(f"Received prompt: ===={prompt}\n====")
222
+ if prompt == "STOP":
223
+ break
224
+
225
+ # 重置计数器和事件
226
+ inference_count = 0
227
+ progress_stop_event.clear()
228
+
229
+ # 启动进度提示线程
230
+ progress_thread = threading.Thread(target=show_progress)
231
+ progress_thread.daemon = True
232
+ # progress_thread.start()
233
+
234
+ image_embeddings = embedding_queue.get()
235
+ if isinstance(image_embeddings, str) and image_embeddings == "ERROR":
236
+ print("Error processing audio")
237
+ continue
238
+ print(image_embeddings.shape)
239
+ rkllm_input = create_rkllm_input(RKLLMInputType.RKLLM_INPUT_MULTIMODAL,
240
+ prompt=prompt,
241
+ image_embed=image_embeddings)
242
+ print(f"Start LLM inference...")
243
+ inference_start_time = time.time()
244
+ run(handle, rkllm_input, infer_param, None)
245
+
246
+ # 清理
247
+ destroy(handle)
248
+
249
+ def main():
250
+ load_ready_queue = Queue()
251
+ embedding_queue = Queue()
252
+ audio_path_queue = Queue()
253
+ prompt_queue = Queue()
254
+ inference_done_queue = Queue()
255
+ start_event = Event()
256
+
257
+ audio_process = Process(target=audio_encoder_process,
258
+ args=(load_ready_queue, embedding_queue, audio_path_queue, start_event))
259
+ lm_process = Process(target=llm_process,
260
+ args=(load_ready_queue, embedding_queue, prompt_queue, inference_done_queue, start_event))
261
+
262
+ audio_process.start()
263
+ time.sleep(10)
264
+ lm_process.start()
265
+
266
+ # 等待模型加载
267
+ ready_count = 0
268
+ while ready_count < 2:
269
+ status = load_ready_queue.get()
270
+ print(f"Received ready signal: {status}")
271
+ ready_count += 1
272
+
273
+ print("All models loaded, starting interactive mode...")
274
+ start_event.set()
275
+
276
+ # 交互循环
277
+ try:
278
+ while True:
279
+ print("""
280
+ Enter your input (3 empty lines to start inference, Ctrl+C to exit, for example:
281
+ 这是什么声音{{glass-breaking.wav}}?
282
+ What kind of sound is in {{./test.mp3}}?
283
+ Describe the audio in {{./test.mp3}}
284
+ 这是什么动物的叫声{{./jntm.mp3}}?
285
+ ):
286
+ """)
287
+ user_input = []
288
+ empty_lines = 0
289
+
290
+ while empty_lines < 3:
291
+ line = input()
292
+ if line.strip() == "":
293
+ empty_lines += 1
294
+ else:
295
+ empty_lines = 0
296
+ user_input.append(line)
297
+
298
+ # 解析输入
299
+ full_input = "\n".join(user_input[:-3]) # 去掉最后3个空行
300
+ import re
301
+ img_match = re.search(r'\{\{(.+?)\}\}', full_input)
302
+ if not img_match:
303
+ print("No image path found in input")
304
+ continue
305
+
306
+ img_path = img_match.group(1)
307
+ # 将音频标记替换为<image>标记, rkllm的<image>是写死的...
308
+ prompt = f"""<|im_start|>system
309
+ You are a helpful assistant.<|im_end|>
310
+ <|im_start|>user
311
+ Audio 1: <image>
312
+ {full_input.replace(img_match.group(0), '')}<|im_end|>
313
+ <|im_start|>assistant
314
+ """
315
+ audio_path_queue.put(img_path)
316
+ prompt_queue.put(prompt)
317
+
318
+ # 等待推理完成
319
+ status = inference_done_queue.get()
320
+ if status == "ERROR":
321
+ print("Inference failed")
322
+
323
+ except KeyboardInterrupt:
324
+ print("\nExiting...")
325
+ audio_path_queue.put("STOP")
326
+ prompt_queue.put("STOP")
327
+
328
+ audio_process.join()
329
+ lm_process.join()
330
+
331
+ if __name__ == "__main__":
332
+ main()
333
+
334
+ #这是什么声音{{./test.mp3}}?
preprocessor_config.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "chunk_length": 30,
3
+ "feature_extractor_type": "WhisperFeatureExtractor",
4
+ "feature_size": 128,
5
+ "hop_length": 160,
6
+ "n_fft": 400,
7
+ "n_samples": 480000,
8
+ "nb_max_frames": 3000,
9
+ "padding_side": "right",
10
+ "padding_value": 0.0,
11
+ "processor_class": "Qwen2AudioProcessor",
12
+ "return_attention_mask": true,
13
+ "sampling_rate": 16000
14
+ }
qwen.rkllm ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:cfd15dce8ce894421f6af38fc82f46c5c53eefd452d8fc9d36391f98179d2f4a
3
+ size 8428376036
rename_tensors.py ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import json
2
+ import os
3
+ import shutil
4
+ import mmap
5
+ import re
6
+
7
+ def rename_tensors():
8
+ # 读取JSON文件
9
+ with open('model.safetensors.index.json', 'r') as f:
10
+ data = json.load(f)
11
+
12
+ # 获取所有唯一的safetensors文件名
13
+ safetensor_files = set(data['weight_map'].values())
14
+
15
+ # 复制并重命名safetensors文件
16
+ for file in safetensor_files:
17
+ new_file = file.replace('model-', 'model-renamed-')
18
+ shutil.copy(file, new_file)
19
+
20
+ # 在新文件的前1MB范围内替换字符串
21
+ with open(new_file, 'r+b') as f:
22
+ mm = mmap.mmap(f.fileno(), 1024*1024) # 映射前1MB
23
+ content = mm.read()
24
+ # 使用字节字符串进行替换
25
+ content = content.replace(b'"language_model.', b' "')
26
+ mm.seek(0)
27
+ mm.write(content)
28
+ mm.close()
29
+
30
+ # 更新JSON数据
31
+ new_weight_map = {}
32
+ for key, value in data['weight_map'].items():
33
+ new_key = re.sub(r'^language_model.', '', key)
34
+ new_value = value.replace('model-', 'model-renamed-')
35
+ new_weight_map[new_key] = new_value
36
+
37
+ data['weight_map'] = new_weight_map
38
+
39
+ # 写入新的JSON文件
40
+ with open('model-renamed.safetensors.index.json', 'w') as f:
41
+ json.dump(data, f, indent=2)
42
+
43
+ print("处理完成。新的JSON文件已生成:model-renamed.safetensors.index.json")
44
+
45
+ if __name__ == "__main__":
46
+ rename_tensors()
rkllm-convert.py ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from rkllm.api import RKLLM
2
+ from datasets import load_dataset
3
+ from transformers import AutoTokenizer
4
+ from tqdm import tqdm
5
+ import torch
6
+ from torch import nn
7
+ import os
8
+ # os.environ['CUDA_VISIBLE_DEVICES']='1'
9
+
10
+ modelpath = '.'
11
+ # modelpath = "./path/to/Qwen-1.8B-F16.gguf"
12
+ llm = RKLLM()
13
+
14
+ # Load model
15
+ # Use 'export CUDA_VISIBLE_DEVICES=2' to specify GPU device
16
+ # options ['cpu', 'cuda']
17
+ ret = llm.load_huggingface(model=modelpath, model_lora = None, device='cpu')
18
+ # ret = llm.load_gguf(model = modelpath)
19
+ if ret != 0:
20
+ print('Load model failed!')
21
+ exit(ret)
22
+
23
+ # Build model
24
+ dataset = "./data_quant.json"
25
+ # Json file format, please note to add prompt in the input,like this:
26
+ # [{"input":"Human: 你好!\nAssistant: ", "target": "你好!我是人工智能助手KK!"},...]
27
+
28
+ qparams = None
29
+ # qparams = 'gdq.qparams' # Use extra_qparams
30
+ ret = llm.build(do_quantization=True, optimization_level=1, quantized_dtype='w8a8',
31
+ quantized_algorithm='normal', target_platform='rk3588', num_npu_core=3, extra_qparams=qparams)
32
+
33
+ if ret != 0:
34
+ print('Build model failed!')
35
+ exit(ret)
36
+
37
+ # Export rkllm model
38
+ ret = llm.export_rkllm("./qwen.rkllm")
39
+ if ret != 0:
40
+ print('Export model failed!')
41
+ exit(ret)
rkllm_binding.py ADDED
@@ -0,0 +1,226 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import ctypes
2
+ import numpy as np
3
+ from enum import IntEnum
4
+ from typing import Callable, Any
5
+
6
+ # Load the shared library
7
+ _lib = ctypes.CDLL("./librkllmrt.so") # Adjust the library name if necessary
8
+
9
+ # Define enums
10
+ class LLMCallState(IntEnum):
11
+ RKLLM_RUN_NORMAL = 0
12
+ RKLLM_RUN_WAITING = 1
13
+ RKLLM_RUN_FINISH = 2
14
+ RKLLM_RUN_ERROR = 3
15
+ RKLLM_RUN_GET_LAST_HIDDEN_LAYER = 4
16
+
17
+ class RKLLMInputType(IntEnum):
18
+ RKLLM_INPUT_PROMPT = 0
19
+ RKLLM_INPUT_TOKEN = 1
20
+ RKLLM_INPUT_EMBED = 2
21
+ RKLLM_INPUT_MULTIMODAL = 3
22
+
23
+ class RKLLMInferMode(IntEnum):
24
+ RKLLM_INFER_GENERATE = 0
25
+ RKLLM_INFER_GET_LAST_HIDDEN_LAYER = 1
26
+
27
+ # Define structures
28
+ class RKLLMExtendParam(ctypes.Structure):
29
+ _fields_ = [
30
+ ("base_domain_id", ctypes.c_int32),
31
+ ("reserved", ctypes.c_uint8 * 112)
32
+ ]
33
+
34
+ class RKLLMParam(ctypes.Structure):
35
+ _fields_ = [
36
+ ("model_path", ctypes.c_char_p),
37
+ ("max_context_len", ctypes.c_int32),
38
+ ("max_new_tokens", ctypes.c_int32),
39
+ ("top_k", ctypes.c_int32),
40
+ ("top_p", ctypes.c_float),
41
+ ("temperature", ctypes.c_float),
42
+ ("repeat_penalty", ctypes.c_float),
43
+ ("frequency_penalty", ctypes.c_float),
44
+ ("presence_penalty", ctypes.c_float),
45
+ ("mirostat", ctypes.c_int32),
46
+ ("mirostat_tau", ctypes.c_float),
47
+ ("mirostat_eta", ctypes.c_float),
48
+ ("skip_special_token", ctypes.c_bool),
49
+ ("is_async", ctypes.c_bool),
50
+ ("img_start", ctypes.c_char_p),
51
+ ("img_end", ctypes.c_char_p),
52
+ ("img_content", ctypes.c_char_p),
53
+ ("extend_param", RKLLMExtendParam)
54
+ ]
55
+
56
+ class RKLLMLoraAdapter(ctypes.Structure):
57
+ _fields_ = [
58
+ ("lora_adapter_path", ctypes.c_char_p),
59
+ ("lora_adapter_name", ctypes.c_char_p),
60
+ ("scale", ctypes.c_float)
61
+ ]
62
+
63
+ class RKLLMEmbedInput(ctypes.Structure):
64
+ _fields_ = [
65
+ ("embed", ctypes.POINTER(ctypes.c_float)),
66
+ ("n_tokens", ctypes.c_size_t)
67
+ ]
68
+
69
+ class RKLLMTokenInput(ctypes.Structure):
70
+ _fields_ = [
71
+ ("input_ids", ctypes.POINTER(ctypes.c_int32)),
72
+ ("n_tokens", ctypes.c_size_t)
73
+ ]
74
+
75
+ class RKLLMMultiModelInput(ctypes.Structure):
76
+ _fields_ = [
77
+ ("prompt", ctypes.c_char_p),
78
+ ("image_embed", ctypes.POINTER(ctypes.c_float)),
79
+ ("n_image_tokens", ctypes.c_size_t)
80
+ ]
81
+
82
+ class RKLLMInput(ctypes.Structure):
83
+ class _InputUnion(ctypes.Union):
84
+ _fields_ = [
85
+ ("prompt_input", ctypes.c_char_p),
86
+ ("embed_input", RKLLMEmbedInput),
87
+ ("token_input", RKLLMTokenInput),
88
+ ("multimodal_input", RKLLMMultiModelInput)
89
+ ]
90
+ _fields_ = [
91
+ ("input_type", ctypes.c_int),
92
+ ("_input", _InputUnion)
93
+ ]
94
+
95
+ class RKLLMLoraParam(ctypes.Structure):
96
+ _fields_ = [
97
+ ("lora_adapter_name", ctypes.c_char_p)
98
+ ]
99
+
100
+ class RKLLMPromptCacheParam(ctypes.Structure):
101
+ _fields_ = [
102
+ ("save_prompt_cache", ctypes.c_int),
103
+ ("prompt_cache_path", ctypes.c_char_p)
104
+ ]
105
+
106
+ class RKLLMInferParam(ctypes.Structure):
107
+ _fields_ = [
108
+ ("mode", ctypes.c_int),
109
+ ("lora_params", ctypes.POINTER(RKLLMLoraParam)),
110
+ ("prompt_cache_params", ctypes.POINTER(RKLLMPromptCacheParam))
111
+ ]
112
+
113
+ class RKLLMResultLastHiddenLayer(ctypes.Structure):
114
+ _fields_ = [
115
+ ("hidden_states", ctypes.POINTER(ctypes.c_float)),
116
+ ("embd_size", ctypes.c_int),
117
+ ("num_tokens", ctypes.c_int)
118
+ ]
119
+
120
+ class RKLLMResult(ctypes.Structure):
121
+ _fields_ = [
122
+ ("text", ctypes.c_char_p),
123
+ ("token_id", ctypes.c_int32),
124
+ ("last_hidden_layer", RKLLMResultLastHiddenLayer)
125
+ ]
126
+
127
+ # Define callback type
128
+ LLMResultCallback = ctypes.CFUNCTYPE(None, ctypes.POINTER(RKLLMResult), ctypes.c_void_p, ctypes.c_int)
129
+
130
+ # Define function prototypes
131
+ _lib.rkllm_createDefaultParam.restype = RKLLMParam
132
+ _lib.rkllm_init.argtypes = [ctypes.POINTER(ctypes.c_void_p), ctypes.POINTER(RKLLMParam), LLMResultCallback]
133
+ _lib.rkllm_init.restype = ctypes.c_int
134
+ _lib.rkllm_load_lora.argtypes = [ctypes.c_void_p, ctypes.POINTER(RKLLMLoraAdapter)]
135
+ _lib.rkllm_load_lora.restype = ctypes.c_int
136
+ _lib.rkllm_load_prompt_cache.argtypes = [ctypes.c_void_p, ctypes.c_char_p]
137
+ _lib.rkllm_load_prompt_cache.restype = ctypes.c_int
138
+ _lib.rkllm_release_prompt_cache.argtypes = [ctypes.c_void_p]
139
+ _lib.rkllm_release_prompt_cache.restype = ctypes.c_int
140
+ _lib.rkllm_destroy.argtypes = [ctypes.c_void_p]
141
+ _lib.rkllm_destroy.restype = ctypes.c_int
142
+ _lib.rkllm_run.argtypes = [ctypes.c_void_p, ctypes.POINTER(RKLLMInput), ctypes.POINTER(RKLLMInferParam), ctypes.c_void_p]
143
+ _lib.rkllm_run.restype = ctypes.c_int
144
+ _lib.rkllm_run_async.argtypes = [ctypes.c_void_p, ctypes.POINTER(RKLLMInput), ctypes.POINTER(RKLLMInferParam), ctypes.c_void_p]
145
+ _lib.rkllm_run_async.restype = ctypes.c_int
146
+ _lib.rkllm_abort.argtypes = [ctypes.c_void_p]
147
+ _lib.rkllm_abort.restype = ctypes.c_int
148
+ _lib.rkllm_is_running.argtypes = [ctypes.c_void_p]
149
+ _lib.rkllm_is_running.restype = ctypes.c_int
150
+
151
+ # Python wrapper functions
152
+ def create_default_param() -> RKLLMParam:
153
+ return _lib.rkllm_createDefaultParam()
154
+
155
+ def init(param: RKLLMParam, callback: Callable[[RKLLMResult, Any, LLMCallState], None]) -> ctypes.c_void_p:
156
+ handle = ctypes.c_void_p()
157
+ c_callback = LLMResultCallback(callback)
158
+ status = _lib.rkllm_init(ctypes.byref(handle), ctypes.byref(param), c_callback)
159
+ if status != 0:
160
+ raise RuntimeError(f"Failed to initialize RKLLM: {status}")
161
+ return handle
162
+
163
+ def load_lora(handle: ctypes.c_void_p, lora_adapter: RKLLMLoraAdapter) -> None:
164
+ status = _lib.rkllm_load_lora(handle, ctypes.byref(lora_adapter))
165
+ if status != 0:
166
+ raise RuntimeError(f"Failed to load Lora adapter: {status}")
167
+
168
+ def load_prompt_cache(handle: ctypes.c_void_p, prompt_cache_path: str) -> None:
169
+ status = _lib.rkllm_load_prompt_cache(handle, prompt_cache_path.encode())
170
+ if status != 0:
171
+ raise RuntimeError(f"Failed to load prompt cache: {status}")
172
+
173
+ def release_prompt_cache(handle: ctypes.c_void_p) -> None:
174
+ status = _lib.rkllm_release_prompt_cache(handle)
175
+ if status != 0:
176
+ raise RuntimeError(f"Failed to release prompt cache: {status}")
177
+
178
+ def destroy(handle: ctypes.c_void_p) -> None:
179
+ status = _lib.rkllm_destroy(handle)
180
+ if status != 0:
181
+ raise RuntimeError(f"Failed to destroy RKLLM: {status}")
182
+
183
+ def run(handle: ctypes.c_void_p, rkllm_input: RKLLMInput, rkllm_infer_params: RKLLMInferParam, userdata: Any) -> None:
184
+ status = _lib.rkllm_run(handle, ctypes.byref(rkllm_input), ctypes.byref(rkllm_infer_params), ctypes.c_void_p(userdata))
185
+ if status != 0:
186
+ raise RuntimeError(f"Failed to run RKLLM: {status}")
187
+
188
+ def run_async(handle: ctypes.c_void_p, rkllm_input: RKLLMInput, rkllm_infer_params: RKLLMInferParam, userdata: Any) -> None:
189
+ status = _lib.rkllm_run_async(handle, ctypes.byref(rkllm_input), ctypes.byref(rkllm_infer_params), ctypes.c_void_p(userdata))
190
+ if status != 0:
191
+ raise RuntimeError(f"Failed to run RKLLM asynchronously: {status}")
192
+
193
+ def abort(handle: ctypes.c_void_p) -> None:
194
+ status = _lib.rkllm_abort(handle)
195
+ if status != 0:
196
+ raise RuntimeError(f"Failed to abort RKLLM: {status}")
197
+
198
+ def is_running(handle: ctypes.c_void_p) -> bool:
199
+ return _lib.rkllm_is_running(handle) == 0
200
+
201
+ # Helper function to convert numpy array to C array
202
+ def numpy_to_c_array(arr: np.ndarray, c_type):
203
+ return arr.ctypes.data_as(ctypes.POINTER(c_type))
204
+
205
+ # Helper function to create RKLLMInput
206
+ def create_rkllm_input(input_type: RKLLMInputType, **kwargs) -> RKLLMInput:
207
+ rkllm_input = RKLLMInput()
208
+ rkllm_input.input_type = input_type.value
209
+
210
+ if input_type == RKLLMInputType.RKLLM_INPUT_PROMPT:
211
+ rkllm_input._input.prompt_input = kwargs['prompt'].encode()
212
+ elif input_type == RKLLMInputType.RKLLM_INPUT_EMBED:
213
+ embed = kwargs['embed']
214
+ rkllm_input._input.embed_input.embed = numpy_to_c_array(embed, ctypes.c_float)
215
+ rkllm_input._input.embed_input.n_tokens = embed.shape[1]
216
+ elif input_type == RKLLMInputType.RKLLM_INPUT_TOKEN:
217
+ tokens = kwargs['tokens']
218
+ rkllm_input._input.token_input.input_ids = numpy_to_c_array(tokens, ctypes.c_int32)
219
+ rkllm_input._input.token_input.n_tokens = tokens.shape[1]
220
+ elif input_type == RKLLMInputType.RKLLM_INPUT_MULTIMODAL:
221
+ rkllm_input._input.multimodal_input.prompt = kwargs['prompt'].encode()
222
+ image_embed = kwargs['image_embed']
223
+ rkllm_input._input.multimodal_input.image_embed = numpy_to_c_array(image_embed, ctypes.c_float)
224
+ rkllm_input._input.multimodal_input.n_image_tokens = image_embed.shape[1]
225
+
226
+ return rkllm_input
run_rknn.py ADDED
@@ -0,0 +1,128 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import os
2
+ import time
3
+ import numpy as np
4
+ from rkllm_binding import *
5
+ from rknnlite.api.rknn_lite import RKNNLite
6
+ from transformers import WhisperFeatureExtractor
7
+ import signal
8
+ import cv2
9
+ import librosa
10
+
11
+
12
+ MODEL_PATH = "qwen.rkllm"
13
+ AUDIO_ENCODER_PATH = "audio_encoder.rknn"
14
+ handle = None
15
+ img_size = 448
16
+
17
+ # exit on ctrl-c
18
+ def signal_handler(signal, frame):
19
+ print("Ctrl-C pressed, exiting...")
20
+ global handle
21
+ if handle:
22
+ abort(handle)
23
+ destroy(handle)
24
+ exit(0)
25
+
26
+ signal.signal(signal.SIGINT, signal_handler)
27
+
28
+ # export RKLLM_LOG_LEVEL=1
29
+ os.environ["RKLLM_LOG_LEVEL"] = "1"
30
+
31
+ inference_count = 0
32
+ inference_start_time = 0
33
+ def result_callback(result, userdata, state):
34
+ global inference_start_time
35
+ global inference_count
36
+ if state == LLMCallState.RKLLM_RUN_NORMAL:
37
+ if inference_count == 0:
38
+ first_token_time = time.time()
39
+ print(f"Time to first token: {first_token_time - inference_start_time:.2f} seconds")
40
+ inference_count += 1
41
+ print(result.contents.text.decode(), end="", flush=True)
42
+ elif state == LLMCallState.RKLLM_RUN_FINISH:
43
+ print("\n\n(finished)")
44
+ elif state == LLMCallState.RKLLM_RUN_ERROR:
45
+ print("\nError occurred during LLM call")
46
+
47
+ feature_extractor = WhisperFeatureExtractor.from_pretrained(".")
48
+
49
+ # Initialize audio encoder
50
+ audio_encoder = RKNNLite(verbose=True)
51
+ model_size = os.path.getsize(AUDIO_ENCODER_PATH)
52
+ print(f"Start loading audio encoder model (size: {model_size / 1024 / 1024:.2f} MB)")
53
+ start_time = time.time()
54
+ audio_encoder.load_rknn(AUDIO_ENCODER_PATH)
55
+ end_time = time.time()
56
+ print(f"Audio encoder loaded in {end_time - start_time:.2f} seconds (speed: {model_size / (end_time - start_time) / 1024 / 1024:.2f} MB/s)")
57
+ audio_encoder.init_runtime()
58
+
59
+ # Initialize RKLLM
60
+ param = create_default_param()
61
+ param.model_path = MODEL_PATH.encode()
62
+ param.img_start = "<|audio_bos|>".encode()
63
+ param.img_end = "<|audio_eos|>".encode()
64
+ param.img_content = "<|AUDIO|>".encode()
65
+ param.max_context_len = 1024
66
+ extend_param = RKLLMExtendParam()
67
+ extend_param.base_domain_id = 1 # iommu domain 0 for audio encoder
68
+ param.extend_param = extend_param
69
+ model_size = os.path.getsize(MODEL_PATH)
70
+ print(f"Start loading language model (size: {model_size / 1024 / 1024:.2f} MB)")
71
+ start_time = time.time()
72
+ handle = init(param, result_callback)
73
+ end_time = time.time()
74
+ print(f"Language model loaded in {end_time - start_time:.2f} seconds (speed: {model_size / (end_time - start_time) / 1024 / 1024:.2f} MB/s)")
75
+
76
+
77
+ # audio embedding
78
+ audio_path = "glass-breaking.mp3"
79
+
80
+
81
+ print("Start inference...")
82
+ audio, _ = librosa.load(audio_path, sr=feature_extractor.sampling_rate)
83
+ feature_extractor_output = feature_extractor(
84
+ audio,
85
+ sampling_rate=feature_extractor.sampling_rate,
86
+ return_attention_mask=True,
87
+ padding="max_length"
88
+ )
89
+
90
+ print(feature_extractor_output.input_features.shape)
91
+ start_time = time.time()
92
+ audio_embeddings = audio_encoder.inference(inputs=[
93
+ feature_extractor_output.input_features.astype(np.float32),
94
+ feature_extractor_output.attention_mask.astype(np.float32)
95
+ ], data_format="nhwc")[0].astype(np.float32)
96
+ end_time = time.time()
97
+ print(f"Audio encoder inference time: {end_time - start_time:.2f} seconds")
98
+ print(audio_embeddings.flags)
99
+ print(audio_embeddings.shape)
100
+
101
+ # Create input. RKLLM is stupid enough to hardcode the <image> tag for embedding.
102
+ prompt = """<|im_start|>system
103
+ You are a helpful assistant.<|im_end|>
104
+ <|im_start|>user
105
+ Audio 1: <image>
106
+ 这是什么声音? <|im_end|>
107
+ <|im_start|>assistant
108
+ """
109
+
110
+ # # # 2.56->3.25>2.41->10.2
111
+ # # image_embeddings = np.load("image_embeddings_pth_orig.npy")
112
+ # # image_embeddings = np.ascontiguousarray(image_embeddings, dtype=np.float32)
113
+ # # print(f"Loaded embeddings shape: {image_embeddings.shape}")
114
+
115
+ # # rkllm_input = create_rkllm_input(RKLLMInputType.RKLLM_INPUT_EMBED, embed=image_embeddings)
116
+
117
+ rkllm_input = create_rkllm_input(RKLLMInputType.RKLLM_INPUT_MULTIMODAL, prompt=prompt, image_embed=audio_embeddings)
118
+
119
+ # Create inference parameters
120
+ infer_param = RKLLMInferParam()
121
+ infer_param.mode = RKLLMInferMode.RKLLM_INFER_GENERATE.value
122
+
123
+ # Run RKLLM
124
+ inference_start_time = time.time()
125
+ run(handle, rkllm_input, infer_param, None)
126
+
127
+ # Clean up
128
+ destroy(handle)
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
The diff for this file is too large to render. See raw diff
 
vocab.json ADDED
The diff for this file is too large to render. See raw diff