QingyiSi commited on
Commit
69c71b7
·
verified ·
1 Parent(s): 99d6282

Add files using upload-large-folder tool

Browse files
.gitattributes CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
chat_template.jinja ADDED
@@ -0,0 +1,120 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {%- if tools %}
2
+ {{- '<|im_start|>system\n' }}
3
+ {%- if messages[0].role == 'system' %}
4
+ {%- if messages[0].content is string %}
5
+ {{- messages[0].content }}
6
+ {%- else %}
7
+ {%- for content in messages[0].content %}
8
+ {%- if 'text' in content %}
9
+ {{- content.text }}
10
+ {%- endif %}
11
+ {%- endfor %}
12
+ {%- endif %}
13
+ {{- '\n\n' }}
14
+ {%- endif %}
15
+ {{- "# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>" }}
16
+ {%- for tool in tools %}
17
+ {{- "\n" }}
18
+ {{- tool | tojson }}
19
+ {%- endfor %}
20
+ {{- "\n</tools>\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{\"name\": <function-name>, \"arguments\": <args-json-object>}\n</tool_call><|im_end|>\n" }}
21
+ {%- else %}
22
+ {%- if messages[0].role == 'system' %}
23
+ {{- '<|im_start|>system\n' }}
24
+ {%- if messages[0].content is string %}
25
+ {{- messages[0].content }}
26
+ {%- else %}
27
+ {%- for content in messages[0].content %}
28
+ {%- if 'text' in content %}
29
+ {{- content.text }}
30
+ {%- endif %}
31
+ {%- endfor %}
32
+ {%- endif %}
33
+ {{- '<|im_end|>\n' }}
34
+ {%- endif %}
35
+ {%- endif %}
36
+ {%- set image_count = namespace(value=0) %}
37
+ {%- set video_count = namespace(value=0) %}
38
+ {%- for message in messages %}
39
+ {%- if message.role == "user" %}
40
+ {{- '<|im_start|>' + message.role + '\n' }}
41
+ {%- if message.content is string %}
42
+ {{- message.content }}
43
+ {%- else %}
44
+ {%- for content in message.content %}
45
+ {%- if content.type == 'image' or 'image' in content or 'image_url' in content %}
46
+ {%- set image_count.value = image_count.value + 1 %}
47
+ {%- if add_vision_id %}Picture {{ image_count.value }}: {% endif -%}
48
+ <|vision_start|><|image_pad|><|vision_end|>
49
+ {%- elif content.type == 'video' or 'video' in content %}
50
+ {%- set video_count.value = video_count.value + 1 %}
51
+ {%- if add_vision_id %}Video {{ video_count.value }}: {% endif -%}
52
+ <|vision_start|><|video_pad|><|vision_end|>
53
+ {%- elif 'text' in content %}
54
+ {{- content.text }}
55
+ {%- endif %}
56
+ {%- endfor %}
57
+ {%- endif %}
58
+ {{- '<|im_end|>\n' }}
59
+ {%- elif message.role == "assistant" %}
60
+ {{- '<|im_start|>' + message.role + '\n' }}
61
+ {%- if message.content is string %}
62
+ {{- message.content }}
63
+ {%- else %}
64
+ {%- for content_item in message.content %}
65
+ {%- if 'text' in content_item %}
66
+ {{- content_item.text }}
67
+ {%- endif %}
68
+ {%- endfor %}
69
+ {%- endif %}
70
+ {%- if message.tool_calls %}
71
+ {%- for tool_call in message.tool_calls %}
72
+ {%- if (loop.first and message.content) or (not loop.first) %}
73
+ {{- '\n' }}
74
+ {%- endif %}
75
+ {%- if tool_call.function %}
76
+ {%- set tool_call = tool_call.function %}
77
+ {%- endif %}
78
+ {{- '<tool_call>\n{"name": "' }}
79
+ {{- tool_call.name }}
80
+ {{- '", "arguments": ' }}
81
+ {%- if tool_call.arguments is string %}
82
+ {{- tool_call.arguments }}
83
+ {%- else %}
84
+ {{- tool_call.arguments | tojson }}
85
+ {%- endif %}
86
+ {{- '}\n</tool_call>' }}
87
+ {%- endfor %}
88
+ {%- endif %}
89
+ {{- '<|im_end|>\n' }}
90
+ {%- elif message.role == "tool" %}
91
+ {%- if loop.first or (messages[loop.index0 - 1].role != "tool") %}
92
+ {{- '<|im_start|>user' }}
93
+ {%- endif %}
94
+ {{- '\n<tool_response>\n' }}
95
+ {%- if message.content is string %}
96
+ {{- message.content }}
97
+ {%- else %}
98
+ {%- for content in message.content %}
99
+ {%- if content.type == 'image' or 'image' in content or 'image_url' in content %}
100
+ {%- set image_count.value = image_count.value + 1 %}
101
+ {%- if add_vision_id %}Picture {{ image_count.value }}: {% endif -%}
102
+ <|vision_start|><|image_pad|><|vision_end|>
103
+ {%- elif content.type == 'video' or 'video' in content %}
104
+ {%- set video_count.value = video_count.value + 1 %}
105
+ {%- if add_vision_id %}Video {{ video_count.value }}: {% endif -%}
106
+ <|vision_start|><|video_pad|><|vision_end|>
107
+ {%- elif 'text' in content %}
108
+ {{- content.text }}
109
+ {%- endif %}
110
+ {%- endfor %}
111
+ {%- endif %}
112
+ {{- '\n</tool_response>' }}
113
+ {%- if loop.last or (messages[loop.index0 + 1].role != "tool") %}
114
+ {{- '<|im_end|>\n' }}
115
+ {%- endif %}
116
+ {%- endif %}
117
+ {%- endfor %}
118
+ {%- if add_generation_prompt %}
119
+ {{- '<|im_start|>assistant\n' }}
120
+ {%- endif %}
config.json ADDED
@@ -0,0 +1,236 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Qwen3VLForConditionalGeneration"
4
+ ],
5
+ "dtype": "bfloat16",
6
+ "eos_token_id": 151645,
7
+ "hidden_size": 4096,
8
+ "image_token_id": 151655,
9
+ "model_type": "qwen3_vl",
10
+ "pad_token_id": 151643,
11
+ "quantization_config": {
12
+ "config_groups": {
13
+ "group_0": {
14
+ "format": "nvfp4-pack-quantized",
15
+ "input_activations": {
16
+ "actorder": null,
17
+ "block_structure": null,
18
+ "dynamic": "local",
19
+ "group_size": 16,
20
+ "num_bits": 4,
21
+ "observer": "static_minmax",
22
+ "observer_kwargs": {},
23
+ "scale_dtype": "torch.float8_e4m3fn",
24
+ "strategy": "tensor_group",
25
+ "symmetric": true,
26
+ "type": "float",
27
+ "zp_dtype": null
28
+ },
29
+ "output_activations": null,
30
+ "targets": [
31
+ "Linear"
32
+ ],
33
+ "weights": {
34
+ "actorder": null,
35
+ "block_structure": null,
36
+ "dynamic": false,
37
+ "group_size": 16,
38
+ "num_bits": 4,
39
+ "observer": "memoryless_minmax",
40
+ "observer_kwargs": {},
41
+ "scale_dtype": "torch.float8_e4m3fn",
42
+ "strategy": "tensor_group",
43
+ "symmetric": true,
44
+ "type": "float",
45
+ "zp_dtype": null
46
+ }
47
+ }
48
+ },
49
+ "format": "nvfp4-pack-quantized",
50
+ "global_compression_ratio": null,
51
+ "ignore": [
52
+ "model.visual.blocks.0.attn.qkv",
53
+ "model.visual.blocks.0.attn.proj",
54
+ "model.visual.blocks.0.mlp.linear_fc1",
55
+ "model.visual.blocks.0.mlp.linear_fc2",
56
+ "model.visual.blocks.1.attn.qkv",
57
+ "model.visual.blocks.1.attn.proj",
58
+ "model.visual.blocks.1.mlp.linear_fc1",
59
+ "model.visual.blocks.1.mlp.linear_fc2",
60
+ "model.visual.blocks.2.attn.qkv",
61
+ "model.visual.blocks.2.attn.proj",
62
+ "model.visual.blocks.2.mlp.linear_fc1",
63
+ "model.visual.blocks.2.mlp.linear_fc2",
64
+ "model.visual.blocks.3.attn.qkv",
65
+ "model.visual.blocks.3.attn.proj",
66
+ "model.visual.blocks.3.mlp.linear_fc1",
67
+ "model.visual.blocks.3.mlp.linear_fc2",
68
+ "model.visual.blocks.4.attn.qkv",
69
+ "model.visual.blocks.4.attn.proj",
70
+ "model.visual.blocks.4.mlp.linear_fc1",
71
+ "model.visual.blocks.4.mlp.linear_fc2",
72
+ "model.visual.blocks.5.attn.qkv",
73
+ "model.visual.blocks.5.attn.proj",
74
+ "model.visual.blocks.5.mlp.linear_fc1",
75
+ "model.visual.blocks.5.mlp.linear_fc2",
76
+ "model.visual.blocks.6.attn.qkv",
77
+ "model.visual.blocks.6.attn.proj",
78
+ "model.visual.blocks.6.mlp.linear_fc1",
79
+ "model.visual.blocks.6.mlp.linear_fc2",
80
+ "model.visual.blocks.7.attn.qkv",
81
+ "model.visual.blocks.7.attn.proj",
82
+ "model.visual.blocks.7.mlp.linear_fc1",
83
+ "model.visual.blocks.7.mlp.linear_fc2",
84
+ "model.visual.blocks.8.attn.qkv",
85
+ "model.visual.blocks.8.attn.proj",
86
+ "model.visual.blocks.8.mlp.linear_fc1",
87
+ "model.visual.blocks.8.mlp.linear_fc2",
88
+ "model.visual.blocks.9.attn.qkv",
89
+ "model.visual.blocks.9.attn.proj",
90
+ "model.visual.blocks.9.mlp.linear_fc1",
91
+ "model.visual.blocks.9.mlp.linear_fc2",
92
+ "model.visual.blocks.10.attn.qkv",
93
+ "model.visual.blocks.10.attn.proj",
94
+ "model.visual.blocks.10.mlp.linear_fc1",
95
+ "model.visual.blocks.10.mlp.linear_fc2",
96
+ "model.visual.blocks.11.attn.qkv",
97
+ "model.visual.blocks.11.attn.proj",
98
+ "model.visual.blocks.11.mlp.linear_fc1",
99
+ "model.visual.blocks.11.mlp.linear_fc2",
100
+ "model.visual.blocks.12.attn.qkv",
101
+ "model.visual.blocks.12.attn.proj",
102
+ "model.visual.blocks.12.mlp.linear_fc1",
103
+ "model.visual.blocks.12.mlp.linear_fc2",
104
+ "model.visual.blocks.13.attn.qkv",
105
+ "model.visual.blocks.13.attn.proj",
106
+ "model.visual.blocks.13.mlp.linear_fc1",
107
+ "model.visual.blocks.13.mlp.linear_fc2",
108
+ "model.visual.blocks.14.attn.qkv",
109
+ "model.visual.blocks.14.attn.proj",
110
+ "model.visual.blocks.14.mlp.linear_fc1",
111
+ "model.visual.blocks.14.mlp.linear_fc2",
112
+ "model.visual.blocks.15.attn.qkv",
113
+ "model.visual.blocks.15.attn.proj",
114
+ "model.visual.blocks.15.mlp.linear_fc1",
115
+ "model.visual.blocks.15.mlp.linear_fc2",
116
+ "model.visual.blocks.16.attn.qkv",
117
+ "model.visual.blocks.16.attn.proj",
118
+ "model.visual.blocks.16.mlp.linear_fc1",
119
+ "model.visual.blocks.16.mlp.linear_fc2",
120
+ "model.visual.blocks.17.attn.qkv",
121
+ "model.visual.blocks.17.attn.proj",
122
+ "model.visual.blocks.17.mlp.linear_fc1",
123
+ "model.visual.blocks.17.mlp.linear_fc2",
124
+ "model.visual.blocks.18.attn.qkv",
125
+ "model.visual.blocks.18.attn.proj",
126
+ "model.visual.blocks.18.mlp.linear_fc1",
127
+ "model.visual.blocks.18.mlp.linear_fc2",
128
+ "model.visual.blocks.19.attn.qkv",
129
+ "model.visual.blocks.19.attn.proj",
130
+ "model.visual.blocks.19.mlp.linear_fc1",
131
+ "model.visual.blocks.19.mlp.linear_fc2",
132
+ "model.visual.blocks.20.attn.qkv",
133
+ "model.visual.blocks.20.attn.proj",
134
+ "model.visual.blocks.20.mlp.linear_fc1",
135
+ "model.visual.blocks.20.mlp.linear_fc2",
136
+ "model.visual.blocks.21.attn.qkv",
137
+ "model.visual.blocks.21.attn.proj",
138
+ "model.visual.blocks.21.mlp.linear_fc1",
139
+ "model.visual.blocks.21.mlp.linear_fc2",
140
+ "model.visual.blocks.22.attn.qkv",
141
+ "model.visual.blocks.22.attn.proj",
142
+ "model.visual.blocks.22.mlp.linear_fc1",
143
+ "model.visual.blocks.22.mlp.linear_fc2",
144
+ "model.visual.blocks.23.attn.qkv",
145
+ "model.visual.blocks.23.attn.proj",
146
+ "model.visual.blocks.23.mlp.linear_fc1",
147
+ "model.visual.blocks.23.mlp.linear_fc2",
148
+ "model.visual.blocks.24.attn.qkv",
149
+ "model.visual.blocks.24.attn.proj",
150
+ "model.visual.blocks.24.mlp.linear_fc1",
151
+ "model.visual.blocks.24.mlp.linear_fc2",
152
+ "model.visual.blocks.25.attn.qkv",
153
+ "model.visual.blocks.25.attn.proj",
154
+ "model.visual.blocks.25.mlp.linear_fc1",
155
+ "model.visual.blocks.25.mlp.linear_fc2",
156
+ "model.visual.blocks.26.attn.qkv",
157
+ "model.visual.blocks.26.attn.proj",
158
+ "model.visual.blocks.26.mlp.linear_fc1",
159
+ "model.visual.blocks.26.mlp.linear_fc2",
160
+ "model.visual.merger.linear_fc1",
161
+ "model.visual.merger.linear_fc2",
162
+ "model.visual.deepstack_merger_list.0.linear_fc1",
163
+ "model.visual.deepstack_merger_list.0.linear_fc2",
164
+ "model.visual.deepstack_merger_list.1.linear_fc1",
165
+ "model.visual.deepstack_merger_list.1.linear_fc2",
166
+ "model.visual.deepstack_merger_list.2.linear_fc1",
167
+ "model.visual.deepstack_merger_list.2.linear_fc2",
168
+ "lm_head"
169
+ ],
170
+ "kv_cache_scheme": null,
171
+ "quant_method": "compressed-tensors",
172
+ "quantization_status": "compressed",
173
+ "sparsity_config": {},
174
+ "transform_config": {},
175
+ "version": "0.17.1"
176
+ },
177
+ "text_config": {
178
+ "attention_bias": false,
179
+ "attention_dropout": 0.0,
180
+ "bos_token_id": 151643,
181
+ "dtype": "bfloat16",
182
+ "eos_token_id": 151645,
183
+ "head_dim": 128,
184
+ "hidden_act": "silu",
185
+ "hidden_size": 4096,
186
+ "initializer_range": 0.02,
187
+ "intermediate_size": 12288,
188
+ "max_position_embeddings": 262144,
189
+ "model_type": "qwen3_vl_text",
190
+ "num_attention_heads": 32,
191
+ "num_hidden_layers": 36,
192
+ "num_key_value_heads": 8,
193
+ "pad_token_id": 151643,
194
+ "rms_norm_eps": 1e-06,
195
+ "rope_parameters": {
196
+ "mrope_interleaved": true,
197
+ "mrope_section": [
198
+ 24,
199
+ 20,
200
+ 20
201
+ ],
202
+ "rope_theta": 5000000,
203
+ "rope_type": "default"
204
+ },
205
+ "use_cache": false,
206
+ "vocab_size": 151936
207
+ },
208
+ "tie_word_embeddings": false,
209
+ "transformers_version": "5.10.1",
210
+ "video_token_id": 151656,
211
+ "vision_config": {
212
+ "deepstack_visual_indexes": [
213
+ 8,
214
+ 16,
215
+ 24
216
+ ],
217
+ "depth": 27,
218
+ "dtype": "bfloat16",
219
+ "hidden_act": "gelu_pytorch_tanh",
220
+ "hidden_size": 1152,
221
+ "in_channels": 3,
222
+ "initializer_range": 0.02,
223
+ "intermediate_size": 4304,
224
+ "model_type": "qwen3_vl_vision",
225
+ "num_heads": 16,
226
+ "num_position_embeddings": 2304,
227
+ "out_hidden_size": 4096,
228
+ "pad_token_id": 151643,
229
+ "patch_size": 16,
230
+ "spatial_merge_size": 2,
231
+ "temporal_patch_size": 2
232
+ },
233
+ "vision_end_token_id": 151653,
234
+ "vision_start_token_id": 151652,
235
+ "vocab_size": 151936
236
+ }
generation_config.json ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "eos_token_id": [
4
+ 151645
5
+ ],
6
+ "pad_token_id": 151643,
7
+ "transformers_version": "5.10.1",
8
+ "use_cache": false
9
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ea6e93eed1af92ecfae3dc702afd78550c337567348e55395c8aa0c9eb1eff55
3
+ size 7549898488
processor_config.json ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "image_processor": {
3
+ "data_format": "channels_first",
4
+ "default_to_square": true,
5
+ "do_convert_rgb": true,
6
+ "do_normalize": true,
7
+ "do_rescale": true,
8
+ "do_resize": true,
9
+ "image_mean": [
10
+ 0.5,
11
+ 0.5,
12
+ 0.5
13
+ ],
14
+ "image_processor_type": "Qwen2VLImageProcessor",
15
+ "image_std": [
16
+ 0.5,
17
+ 0.5,
18
+ 0.5
19
+ ],
20
+ "merge_size": 2,
21
+ "patch_size": 16,
22
+ "resample": 3,
23
+ "rescale_factor": 0.00392156862745098,
24
+ "size": {
25
+ "longest_edge": 16777216,
26
+ "shortest_edge": 65536
27
+ },
28
+ "temporal_patch_size": 2
29
+ },
30
+ "processor_class": "Qwen3VLProcessor",
31
+ "video_processor": {
32
+ "data_format": "channels_first",
33
+ "default_to_square": true,
34
+ "do_convert_rgb": true,
35
+ "do_normalize": true,
36
+ "do_rescale": true,
37
+ "do_resize": true,
38
+ "do_sample_frames": true,
39
+ "fps": 2,
40
+ "image_mean": [
41
+ 0.5,
42
+ 0.5,
43
+ 0.5
44
+ ],
45
+ "image_std": [
46
+ 0.5,
47
+ 0.5,
48
+ 0.5
49
+ ],
50
+ "max_frames": 768,
51
+ "merge_size": 2,
52
+ "min_frames": 4,
53
+ "patch_size": 16,
54
+ "resample": 3,
55
+ "rescale_factor": 0.00392156862745098,
56
+ "return_metadata": false,
57
+ "size": {
58
+ "longest_edge": 25165824,
59
+ "shortest_edge": 4096
60
+ },
61
+ "temporal_patch_size": 2,
62
+ "video_processor_type": "Qwen3VLVideoProcessor"
63
+ }
64
+ }
recipe.yaml ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ default_stage:
2
+ default_modifiers:
3
+ QuantizationModifier:
4
+ targets: [Linear]
5
+ ignore: ['re:.*lm_head', 're:visual.*', 're:model.visual.*', 're:.*mlp.gate$']
6
+ scheme: NVFP4
7
+ bypass_divisibility_checks: false
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:81b7cfe146263a5f08f6dfcbcc4047b65307f4f67e3d0d62eebc1c9f6fd3567e
3
+ size 11423025
tokenizer_config.json ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_prefix_space": false,
3
+ "backend": "tokenizers",
4
+ "bos_token": null,
5
+ "clean_up_tokenization_spaces": false,
6
+ "eos_token": "<|im_end|>",
7
+ "errors": "replace",
8
+ "is_local": true,
9
+ "local_files_only": false,
10
+ "model_max_length": 262144,
11
+ "pad_token": "<|endoftext|>",
12
+ "padding_side": "right",
13
+ "processor_class": "Qwen3VLProcessor",
14
+ "split_special_tokens": false,
15
+ "tokenizer_class": "Qwen2Tokenizer",
16
+ "unk_token": null,
17
+ "use_fast": true
18
+ }