U4R
/

Safetensors
chimera
custom_code
Potentialts commited on
Commit
c6b29f4
·
1 Parent(s): b2ad7b1

upload model weights

Browse files
added_tokens.json ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "</box>": 151654,
3
+ "</domain>": 151656,
4
+ "</img>": 151647,
5
+ "</quad>": 151650,
6
+ "</ref>": 151652,
7
+ "<DOMAIN_0_CONTEXT>": 151657,
8
+ "<IMG_CONTEXT>": 151648,
9
+ "<box>": 151653,
10
+ "<domain>": 151655,
11
+ "<img>": 151646,
12
+ "<quad>": 151649,
13
+ "<ref>": 151651,
14
+ "<|endoftext|>": 151643,
15
+ "<|im_end|>": 151645,
16
+ "<|im_start|>": 151644
17
+ }
config.json ADDED
@@ -0,0 +1,354 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_commit_hash": null,
3
+ "_name_or_path": "/mnt/workspace/Chimera/checkpoints/solva-extractor-1B",
4
+ "architectures": [
5
+ "ChimeraChatModel"
6
+ ],
7
+ "auto_map": {
8
+ "AutoConfig": "configuration_chimera.ChimeraChatConfig",
9
+ "AutoModel": "modeling_chimera.ChimeraChatModel",
10
+ "AutoModelForCausalLM": "modeling_chimera.ChimeraChatModel"
11
+ },
12
+ "downsample_ratio": 0.5,
13
+ "dynamic_image_size": true,
14
+ "expert_encoder_config": {
15
+ "_attn_implementation_internal": null,
16
+ "_commit_hash": null,
17
+ "_name_or_path": "",
18
+ "add_cross_attention": false,
19
+ "architectures": null,
20
+ "bad_words_ids": null,
21
+ "begin_suppress_tokens": null,
22
+ "bos_token_id": null,
23
+ "chunk_size_feed_forward": 0,
24
+ "config_list": [
25
+ {
26
+ "config": {
27
+ "_name_or_path": "/cpfs01/shared/ADLab/datasets/science_dataset/solva_modules/ocr_got",
28
+ "add_cross_attention": false,
29
+ "architectures": [
30
+ "GoTVisionModel"
31
+ ],
32
+ "bad_words_ids": null,
33
+ "begin_suppress_tokens": null,
34
+ "bos_token_id": null,
35
+ "chunk_size_feed_forward": 0,
36
+ "cross_attention_hidden_size": null,
37
+ "decoder_start_token_id": null,
38
+ "depth": 12,
39
+ "diversity_penalty": 0.0,
40
+ "do_sample": false,
41
+ "early_stopping": false,
42
+ "embed_dim": 768,
43
+ "encoder_no_repeat_ngram_size": 0,
44
+ "eos_token_id": null,
45
+ "exponential_decay_length_penalty": null,
46
+ "finetuning_task": null,
47
+ "forced_bos_token_id": null,
48
+ "forced_eos_token_id": null,
49
+ "global_attn_indexes": [
50
+ 2,
51
+ 5,
52
+ 8,
53
+ 11
54
+ ],
55
+ "hidden_size": 1024,
56
+ "id2label": {
57
+ "0": "LABEL_0",
58
+ "1": "LABEL_1"
59
+ },
60
+ "img_size": 1024,
61
+ "in_chans": 3,
62
+ "is_decoder": false,
63
+ "is_encoder_decoder": false,
64
+ "label2id": {
65
+ "LABEL_0": 0,
66
+ "LABEL_1": 1
67
+ },
68
+ "length_penalty": 1.0,
69
+ "max_length": 20,
70
+ "min_length": 0,
71
+ "mlp_ratio": 4,
72
+ "model_type": "got_vision_model",
73
+ "no_repeat_ngram_size": 0,
74
+ "num_beam_groups": 1,
75
+ "num_beams": 1,
76
+ "num_heads": 12,
77
+ "num_return_sequences": 1,
78
+ "out_chans": 256,
79
+ "output_attentions": false,
80
+ "output_hidden_states": false,
81
+ "output_scores": false,
82
+ "pad_token_id": null,
83
+ "patch_size": 16,
84
+ "prefix": null,
85
+ "problem_type": null,
86
+ "pruned_heads": {},
87
+ "qkv_bias": true,
88
+ "rel_pos_zero_init": true,
89
+ "remove_invalid_values": false,
90
+ "repetition_penalty": 1.0,
91
+ "return_dict": true,
92
+ "return_dict_in_generate": false,
93
+ "sep_token_id": null,
94
+ "suppress_tokens": null,
95
+ "task_specific_params": null,
96
+ "temperature": 1.0,
97
+ "tf_legacy_loss": false,
98
+ "tie_encoder_decoder": false,
99
+ "tie_word_embeddings": true,
100
+ "tokenizer_class": null,
101
+ "top_k": 50,
102
+ "top_p": 1.0,
103
+ "torch_dtype": "float32",
104
+ "torchscript": false,
105
+ "transformers_version": "4.44.2",
106
+ "typical_p": 1.0,
107
+ "use_abs_pos": true,
108
+ "use_bfloat16": false,
109
+ "use_rel_pos": true,
110
+ "window_size": 14
111
+ },
112
+ "domain": "ocr",
113
+ "index": 0,
114
+ "select_layer": -1
115
+ }
116
+ ],
117
+ "cross_attention_hidden_size": null,
118
+ "decoder_start_token_id": null,
119
+ "diversity_penalty": 0.0,
120
+ "do_sample": false,
121
+ "early_stopping": false,
122
+ "encoder_no_repeat_ngram_size": 0,
123
+ "eos_token_id": null,
124
+ "exponential_decay_length_penalty": null,
125
+ "finetuning_task": null,
126
+ "forced_bos_token_id": null,
127
+ "forced_eos_token_id": null,
128
+ "id2label": {
129
+ "0": "LABEL_0",
130
+ "1": "LABEL_1"
131
+ },
132
+ "is_decoder": false,
133
+ "is_encoder_decoder": false,
134
+ "label2id": {
135
+ "LABEL_0": 0,
136
+ "LABEL_1": 1
137
+ },
138
+ "length_penalty": 1.0,
139
+ "llm_hidden_size": 896,
140
+ "max_length": 20,
141
+ "min_length": 0,
142
+ "no_repeat_ngram_size": 0,
143
+ "num_beam_groups": 1,
144
+ "num_beams": 1,
145
+ "num_encoder": 1,
146
+ "num_return_sequences": 1,
147
+ "output_attentions": false,
148
+ "output_hidden_states": false,
149
+ "output_scores": false,
150
+ "pad_token_id": null,
151
+ "prefix": null,
152
+ "problem_type": null,
153
+ "pruned_heads": {},
154
+ "remove_invalid_values": false,
155
+ "repetition_penalty": 1.0,
156
+ "return_dict": true,
157
+ "return_dict_in_generate": false,
158
+ "sep_token_id": null,
159
+ "separate_load": false,
160
+ "suppress_tokens": null,
161
+ "task_specific_params": null,
162
+ "temperature": 1.0,
163
+ "tf_legacy_loss": false,
164
+ "tie_encoder_decoder": false,
165
+ "tie_word_embeddings": true,
166
+ "tokenizer_class": null,
167
+ "top_k": 50,
168
+ "top_p": 1.0,
169
+ "torch_dtype": null,
170
+ "torchscript": false,
171
+ "transformers_version": null,
172
+ "typical_p": 1.0,
173
+ "use_bfloat16": false
174
+ },
175
+ "force_image_size": 448,
176
+ "llm_config": {
177
+ "_name_or_path": "Qwen/Qwen2-0.5B-Instruct",
178
+ "add_cross_attention": false,
179
+ "architectures": [
180
+ "Qwen2ForCausalLM"
181
+ ],
182
+ "attention_dropout": 0.0,
183
+ "bad_words_ids": null,
184
+ "begin_suppress_tokens": null,
185
+ "bos_token_id": 151643,
186
+ "chunk_size_feed_forward": 0,
187
+ "cross_attention_hidden_size": null,
188
+ "decoder_start_token_id": null,
189
+ "diversity_penalty": 0.0,
190
+ "do_sample": false,
191
+ "early_stopping": false,
192
+ "encoder_no_repeat_ngram_size": 0,
193
+ "eos_token_id": 151645,
194
+ "exponential_decay_length_penalty": null,
195
+ "finetuning_task": null,
196
+ "forced_bos_token_id": null,
197
+ "forced_eos_token_id": null,
198
+ "hidden_act": "silu",
199
+ "hidden_size": 896,
200
+ "id2label": {
201
+ "0": "LABEL_0",
202
+ "1": "LABEL_1"
203
+ },
204
+ "initializer_range": 0.02,
205
+ "intermediate_size": 4864,
206
+ "is_decoder": false,
207
+ "is_encoder_decoder": false,
208
+ "label2id": {
209
+ "LABEL_0": 0,
210
+ "LABEL_1": 1
211
+ },
212
+ "length_penalty": 1.0,
213
+ "max_length": 20,
214
+ "max_position_embeddings": 32768,
215
+ "max_window_layers": 24,
216
+ "min_length": 0,
217
+ "model_type": "qwen2",
218
+ "no_repeat_ngram_size": 0,
219
+ "num_attention_heads": 14,
220
+ "num_beam_groups": 1,
221
+ "num_beams": 1,
222
+ "num_hidden_layers": 24,
223
+ "num_key_value_heads": 2,
224
+ "num_return_sequences": 1,
225
+ "output_attentions": false,
226
+ "output_hidden_states": false,
227
+ "output_scores": false,
228
+ "pad_token_id": null,
229
+ "prefix": null,
230
+ "problem_type": null,
231
+ "pruned_heads": {},
232
+ "remove_invalid_values": false,
233
+ "repetition_penalty": 1.0,
234
+ "return_dict": true,
235
+ "return_dict_in_generate": false,
236
+ "rms_norm_eps": 1e-06,
237
+ "rope_theta": 1000000.0,
238
+ "sep_token_id": null,
239
+ "sliding_window": null,
240
+ "suppress_tokens": null,
241
+ "task_specific_params": null,
242
+ "temperature": 1.0,
243
+ "tf_legacy_loss": false,
244
+ "tie_encoder_decoder": false,
245
+ "tie_word_embeddings": true,
246
+ "tokenizer_class": null,
247
+ "top_k": 50,
248
+ "top_p": 1.0,
249
+ "torch_dtype": "bfloat16",
250
+ "torchscript": false,
251
+ "transformers_version": "4.44.2",
252
+ "typical_p": 1.0,
253
+ "use_bfloat16": true,
254
+ "use_cache": false,
255
+ "use_sliding_window": false,
256
+ "vocab_size": 151658
257
+ },
258
+ "max_dynamic_patch": 6,
259
+ "min_dynamic_patch": 1,
260
+ "model_type": "chimera",
261
+ "pad2square": false,
262
+ "ps_version": "v2",
263
+ "select_layer": -1,
264
+ "template": "solva-chat-hermes-ocr",
265
+ "torch_dtype": "bfloat16",
266
+ "transformers_version": null,
267
+ "use_backbone_lora": 0,
268
+ "use_llm_lora": 0,
269
+ "use_thumbnail": true,
270
+ "vision_config": {
271
+ "_name_or_path": "",
272
+ "add_cross_attention": false,
273
+ "architectures": [
274
+ "InternVisionModel"
275
+ ],
276
+ "attention_dropout": 0.0,
277
+ "bad_words_ids": null,
278
+ "begin_suppress_tokens": null,
279
+ "bos_token_id": null,
280
+ "chunk_size_feed_forward": 0,
281
+ "cross_attention_hidden_size": null,
282
+ "decoder_start_token_id": null,
283
+ "diversity_penalty": 0.0,
284
+ "do_sample": false,
285
+ "drop_path_rate": 0.1,
286
+ "dropout": 0.0,
287
+ "early_stopping": false,
288
+ "encoder_no_repeat_ngram_size": 0,
289
+ "eos_token_id": null,
290
+ "exponential_decay_length_penalty": null,
291
+ "finetuning_task": null,
292
+ "forced_bos_token_id": null,
293
+ "forced_eos_token_id": null,
294
+ "hidden_act": "gelu",
295
+ "hidden_size": 1024,
296
+ "id2label": {
297
+ "0": "LABEL_0",
298
+ "1": "LABEL_1"
299
+ },
300
+ "image_size": 448,
301
+ "initializer_factor": 1.0,
302
+ "initializer_range": 0.02,
303
+ "intermediate_size": 4096,
304
+ "is_decoder": false,
305
+ "is_encoder_decoder": false,
306
+ "label2id": {
307
+ "LABEL_0": 0,
308
+ "LABEL_1": 1
309
+ },
310
+ "layer_norm_eps": 1e-06,
311
+ "length_penalty": 1.0,
312
+ "max_length": 20,
313
+ "min_length": 0,
314
+ "model_type": "intern_vit_6b",
315
+ "no_repeat_ngram_size": 0,
316
+ "norm_type": "layer_norm",
317
+ "num_attention_heads": 16,
318
+ "num_beam_groups": 1,
319
+ "num_beams": 1,
320
+ "num_channels": 3,
321
+ "num_hidden_layers": 24,
322
+ "num_return_sequences": 1,
323
+ "output_attentions": false,
324
+ "output_hidden_states": false,
325
+ "output_scores": false,
326
+ "pad_token_id": null,
327
+ "patch_size": 14,
328
+ "prefix": null,
329
+ "problem_type": null,
330
+ "pruned_heads": {},
331
+ "qk_normalization": false,
332
+ "qkv_bias": true,
333
+ "remove_invalid_values": false,
334
+ "repetition_penalty": 1.0,
335
+ "return_dict": true,
336
+ "return_dict_in_generate": false,
337
+ "sep_token_id": null,
338
+ "suppress_tokens": null,
339
+ "task_specific_params": null,
340
+ "temperature": 1.0,
341
+ "tf_legacy_loss": false,
342
+ "tie_encoder_decoder": false,
343
+ "tie_word_embeddings": true,
344
+ "tokenizer_class": null,
345
+ "top_k": 50,
346
+ "top_p": 1.0,
347
+ "torch_dtype": "bfloat16",
348
+ "torchscript": false,
349
+ "transformers_version": "4.44.2",
350
+ "typical_p": 1.0,
351
+ "use_bfloat16": true,
352
+ "use_flash_attn": true
353
+ }
354
+ }
generation_config.json ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "eos_token_id": [
4
+ 151644,
5
+ 151645
6
+ ],
7
+ "transformers_version": "4.44.2"
8
+ }
merges.txt ADDED
The diff for this file is too large to render. See raw diff
 
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:013693a79d122be0ce3706ccc63067203eddf56baf9139fd3d0734baeb2b7522
3
+ size 2071018960
processor_config.json ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "expert_processor_list": [
3
+ {
4
+ "_processor_class": null,
5
+ "image_processor_type": "GOTImageProcessor",
6
+ "image_size": 1024,
7
+ "max_patches": 256,
8
+ "mean": [
9
+ 0.48145466,
10
+ 0.4578275,
11
+ 0.40821073
12
+ ],
13
+ "std": [
14
+ 0.26862954,
15
+ 0.26130258,
16
+ 0.27577711
17
+ ]
18
+ }
19
+ ]
20
+ }
special_tokens_map.json ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "additional_special_tokens": [
3
+ "<|im_start|>",
4
+ "<|im_end|>",
5
+ "<img>",
6
+ "</img>",
7
+ "<IMG_CONTEXT>",
8
+ "<quad>",
9
+ "</quad>",
10
+ "<ref>",
11
+ "</ref>",
12
+ "<box>",
13
+ "</box>",
14
+ "<domain>",
15
+ "</domain>",
16
+ "<DOMAIN_0_CONTEXT>"
17
+ ],
18
+ "eos_token": {
19
+ "content": "<|im_end|>",
20
+ "lstrip": false,
21
+ "normalized": false,
22
+ "rstrip": false,
23
+ "single_word": false
24
+ },
25
+ "pad_token": {
26
+ "content": "<|endoftext|>",
27
+ "lstrip": false,
28
+ "normalized": false,
29
+ "rstrip": false,
30
+ "single_word": false
31
+ }
32
+ }
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,152 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_eos_token": false,
3
+ "add_prefix_space": false,
4
+ "added_tokens_decoder": {
5
+ "151643": {
6
+ "content": "<|endoftext|>",
7
+ "lstrip": false,
8
+ "normalized": false,
9
+ "rstrip": false,
10
+ "single_word": false,
11
+ "special": true
12
+ },
13
+ "151644": {
14
+ "content": "<|im_start|>",
15
+ "lstrip": false,
16
+ "normalized": false,
17
+ "rstrip": false,
18
+ "single_word": false,
19
+ "special": true
20
+ },
21
+ "151645": {
22
+ "content": "<|im_end|>",
23
+ "lstrip": false,
24
+ "normalized": false,
25
+ "rstrip": false,
26
+ "single_word": false,
27
+ "special": true
28
+ },
29
+ "151646": {
30
+ "content": "<img>",
31
+ "lstrip": false,
32
+ "normalized": false,
33
+ "rstrip": false,
34
+ "single_word": false,
35
+ "special": true
36
+ },
37
+ "151647": {
38
+ "content": "</img>",
39
+ "lstrip": false,
40
+ "normalized": false,
41
+ "rstrip": false,
42
+ "single_word": false,
43
+ "special": true
44
+ },
45
+ "151648": {
46
+ "content": "<IMG_CONTEXT>",
47
+ "lstrip": false,
48
+ "normalized": false,
49
+ "rstrip": false,
50
+ "single_word": false,
51
+ "special": true
52
+ },
53
+ "151649": {
54
+ "content": "<quad>",
55
+ "lstrip": false,
56
+ "normalized": false,
57
+ "rstrip": false,
58
+ "single_word": false,
59
+ "special": true
60
+ },
61
+ "151650": {
62
+ "content": "</quad>",
63
+ "lstrip": false,
64
+ "normalized": false,
65
+ "rstrip": false,
66
+ "single_word": false,
67
+ "special": true
68
+ },
69
+ "151651": {
70
+ "content": "<ref>",
71
+ "lstrip": false,
72
+ "normalized": false,
73
+ "rstrip": false,
74
+ "single_word": false,
75
+ "special": true
76
+ },
77
+ "151652": {
78
+ "content": "</ref>",
79
+ "lstrip": false,
80
+ "normalized": false,
81
+ "rstrip": false,
82
+ "single_word": false,
83
+ "special": true
84
+ },
85
+ "151653": {
86
+ "content": "<box>",
87
+ "lstrip": false,
88
+ "normalized": false,
89
+ "rstrip": false,
90
+ "single_word": false,
91
+ "special": true
92
+ },
93
+ "151654": {
94
+ "content": "</box>",
95
+ "lstrip": false,
96
+ "normalized": false,
97
+ "rstrip": false,
98
+ "single_word": false,
99
+ "special": true
100
+ },
101
+ "151655": {
102
+ "content": "<domain>",
103
+ "lstrip": false,
104
+ "normalized": false,
105
+ "rstrip": false,
106
+ "single_word": false,
107
+ "special": true
108
+ },
109
+ "151656": {
110
+ "content": "</domain>",
111
+ "lstrip": false,
112
+ "normalized": false,
113
+ "rstrip": false,
114
+ "single_word": false,
115
+ "special": true
116
+ },
117
+ "151657": {
118
+ "content": "<DOMAIN_0_CONTEXT>",
119
+ "lstrip": false,
120
+ "normalized": false,
121
+ "rstrip": false,
122
+ "single_word": false,
123
+ "special": true
124
+ }
125
+ },
126
+ "additional_special_tokens": [
127
+ "<|im_start|>",
128
+ "<|im_end|>",
129
+ "<img>",
130
+ "</img>",
131
+ "<IMG_CONTEXT>",
132
+ "<quad>",
133
+ "</quad>",
134
+ "<ref>",
135
+ "</ref>",
136
+ "<box>",
137
+ "</box>",
138
+ "<domain>",
139
+ "</domain>",
140
+ "<DOMAIN_0_CONTEXT>"
141
+ ],
142
+ "bos_token": null,
143
+ "chat_template": "{% for message in messages %}{% if loop.first and messages[0]['role'] != 'system' %}{{ '<|im_start|>system\nYou are a helpful assistant.<|im_end|>\n' }}{% endif %}{{'<|im_start|>' + message['role'] + '\n' + message['content'] + '<|im_end|>' + '\n'}}{% endfor %}{% if add_generation_prompt %}{{ '<|im_start|>assistant\n' }}{% endif %}",
144
+ "clean_up_tokenization_spaces": false,
145
+ "eos_token": "<|im_end|>",
146
+ "errors": "replace",
147
+ "model_max_length": 8192,
148
+ "pad_token": "<|endoftext|>",
149
+ "split_special_tokens": false,
150
+ "tokenizer_class": "Qwen2Tokenizer",
151
+ "unk_token": null
152
+ }
vocab.json ADDED
The diff for this file is too large to render. See raw diff