xugefu commited on
Commit
78a5030
1 Parent(s): c89f4bd

Upload processor

Browse files
chat_template.json CHANGED
@@ -1,3 +1,3 @@
1
- {
2
- "chat_template": "{% for message in messages %}{{message['role'].capitalize()}}{% if message['content'][0]['type'] == 'image' %}{{':'}}{% else %}{{': '}}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{line['text']}}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}<end_of_utterance>\n{% endfor %}{% if add_generation_prompt %}{{ 'Assistant:' }}{% endif %}"
3
- }
 
1
+ {
2
+ "chat_template": "{% for message in messages %}{{message['role'].capitalize()}}{% if message['content'][0]['type'] == 'image' %}{{':'}}{% else %}{{': '}}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{line['text']}}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}<end_of_utterance>\n{% endfor %}{% if add_generation_prompt %}{{ 'Assistant:' }}{% endif %}"
3
+ }
preprocessor_config.json CHANGED
@@ -1,26 +1,26 @@
1
- {
2
- "do_convert_rgb": true,
3
- "do_image_splitting": false,
4
- "do_normalize": true,
5
- "do_pad": true,
6
- "do_rescale": true,
7
- "do_resize": true,
8
- "image_mean": [
9
- 0.5,
10
- 0.5,
11
- 0.5
12
- ],
13
- "image_processor_type": "Idefics2ImageProcessor",
14
- "image_std": [
15
- 0.5,
16
- 0.5,
17
- 0.5
18
- ],
19
- "processor_class": "Idefics2Processor",
20
- "resample": 2,
21
- "rescale_factor": 0.00392156862745098,
22
- "size": {
23
- "longest_edge": 980,
24
- "shortest_edge": 378
25
- }
26
- }
 
1
+ {
2
+ "do_convert_rgb": true,
3
+ "do_image_splitting": false,
4
+ "do_normalize": true,
5
+ "do_pad": true,
6
+ "do_rescale": true,
7
+ "do_resize": true,
8
+ "image_mean": [
9
+ 0.5,
10
+ 0.5,
11
+ 0.5
12
+ ],
13
+ "image_processor_type": "Idefics2ImageProcessor",
14
+ "image_std": [
15
+ 0.5,
16
+ 0.5,
17
+ 0.5
18
+ ],
19
+ "processor_class": "Idefics2Processor",
20
+ "resample": 2,
21
+ "rescale_factor": 0.00392156862745098,
22
+ "size": {
23
+ "longest_edge": 980,
24
+ "shortest_edge": 378
25
+ }
26
+ }
processor_config.json CHANGED
@@ -1,5 +1,5 @@
1
- {
2
- "chat_template": "{% for message in messages %}{{message['role'].capitalize()}}{% if message['content'][0]['type'] == 'image' %}{{':'}}{% else %}{{': '}}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{line['text']}}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}<end_of_utterance>\n{% endfor %}{% if add_generation_prompt %}{{ 'Assistant:' }}{% endif %}",
3
- "image_seq_len": 64,
4
- "processor_class": "Idefics2Processor"
5
- }
 
1
+ {
2
+ "chat_template": "{% for message in messages %}{{message['role'].capitalize()}}{% if message['content'][0]['type'] == 'image' %}{{':'}}{% else %}{{': '}}{% endif %}{% for line in message['content'] %}{% if line['type'] == 'text' %}{{line['text']}}{% elif line['type'] == 'image' %}{{ '<image>' }}{% endif %}{% endfor %}<end_of_utterance>\n{% endfor %}{% if add_generation_prompt %}{{ 'Assistant:' }}{% endif %}",
3
+ "image_seq_len": 64,
4
+ "processor_class": "Idefics2Processor"
5
+ }
special_tokens_map.json CHANGED
@@ -1,47 +1,47 @@
1
- {
2
- "additional_special_tokens": [
3
- {
4
- "content": "<fake_token_around_image>",
5
- "lstrip": false,
6
- "normalized": false,
7
- "rstrip": false,
8
- "single_word": false
9
- },
10
- {
11
- "content": "<image>",
12
- "lstrip": false,
13
- "normalized": false,
14
- "rstrip": false,
15
- "single_word": false
16
- },
17
- {
18
- "content": "<end_of_utterance>",
19
- "lstrip": false,
20
- "normalized": false,
21
- "rstrip": false,
22
- "single_word": false
23
- }
24
- ],
25
- "bos_token": {
26
- "content": "<s>",
27
- "lstrip": false,
28
- "normalized": false,
29
- "rstrip": false,
30
- "single_word": false
31
- },
32
- "eos_token": {
33
- "content": "</s>",
34
- "lstrip": false,
35
- "normalized": false,
36
- "rstrip": false,
37
- "single_word": false
38
- },
39
- "pad_token": "<pad>",
40
- "unk_token": {
41
- "content": "<unk>",
42
- "lstrip": false,
43
- "normalized": false,
44
- "rstrip": false,
45
- "single_word": false
46
- }
47
- }
 
1
+ {
2
+ "additional_special_tokens": [
3
+ {
4
+ "content": "<fake_token_around_image>",
5
+ "lstrip": false,
6
+ "normalized": false,
7
+ "rstrip": false,
8
+ "single_word": false
9
+ },
10
+ {
11
+ "content": "<image>",
12
+ "lstrip": false,
13
+ "normalized": false,
14
+ "rstrip": false,
15
+ "single_word": false
16
+ },
17
+ {
18
+ "content": "<end_of_utterance>",
19
+ "lstrip": false,
20
+ "normalized": false,
21
+ "rstrip": false,
22
+ "single_word": false
23
+ }
24
+ ],
25
+ "bos_token": {
26
+ "content": "<s>",
27
+ "lstrip": false,
28
+ "normalized": false,
29
+ "rstrip": false,
30
+ "single_word": false
31
+ },
32
+ "eos_token": {
33
+ "content": "</s>",
34
+ "lstrip": false,
35
+ "normalized": false,
36
+ "rstrip": false,
37
+ "single_word": false
38
+ },
39
+ "pad_token": "<pad>",
40
+ "unk_token": {
41
+ "content": "<unk>",
42
+ "lstrip": false,
43
+ "normalized": false,
44
+ "rstrip": false,
45
+ "single_word": false
46
+ }
47
+ }
tokenizer_config.json CHANGED
@@ -1,81 +1,81 @@
1
- {
2
- "add_bos_token": true,
3
- "add_eos_token": false,
4
- "add_prefix_space": null,
5
- "added_tokens_decoder": {
6
- "0": {
7
- "content": "<unk>",
8
- "lstrip": false,
9
- "normalized": false,
10
- "rstrip": false,
11
- "single_word": false,
12
- "special": true
13
- },
14
- "1": {
15
- "content": "<s>",
16
- "lstrip": false,
17
- "normalized": false,
18
- "rstrip": false,
19
- "single_word": false,
20
- "special": true
21
- },
22
- "2": {
23
- "content": "</s>",
24
- "lstrip": false,
25
- "normalized": false,
26
- "rstrip": false,
27
- "single_word": false,
28
- "special": true
29
- },
30
- "32000": {
31
- "content": "<fake_token_around_image>",
32
- "lstrip": false,
33
- "normalized": false,
34
- "rstrip": false,
35
- "single_word": false,
36
- "special": true
37
- },
38
- "32001": {
39
- "content": "<image>",
40
- "lstrip": false,
41
- "normalized": false,
42
- "rstrip": false,
43
- "single_word": false,
44
- "special": true
45
- },
46
- "32002": {
47
- "content": "<end_of_utterance>",
48
- "lstrip": false,
49
- "normalized": false,
50
- "rstrip": false,
51
- "single_word": false,
52
- "special": true
53
- },
54
- "32003": {
55
- "content": "<pad>",
56
- "lstrip": false,
57
- "normalized": false,
58
- "rstrip": false,
59
- "single_word": false,
60
- "special": true
61
- }
62
- },
63
- "additional_special_tokens": [
64
- "<fake_token_around_image>",
65
- "<image>",
66
- "<end_of_utterance>"
67
- ],
68
- "bos_token": "<s>",
69
- "clean_up_tokenization_spaces": false,
70
- "do_image_splitting": false,
71
- "eos_token": "</s>",
72
- "legacy": false,
73
- "model_max_length": 1000000000000000019884624838656,
74
- "pad_token": "<pad>",
75
- "processor_class": "Idefics2Processor",
76
- "sp_model_kwargs": {},
77
- "spaces_between_special_tokens": false,
78
- "tokenizer_class": "LlamaTokenizer",
79
- "unk_token": "<unk>",
80
- "use_default_system_prompt": true
81
- }
 
1
+ {
2
+ "add_bos_token": true,
3
+ "add_eos_token": false,
4
+ "add_prefix_space": null,
5
+ "added_tokens_decoder": {
6
+ "0": {
7
+ "content": "<unk>",
8
+ "lstrip": false,
9
+ "normalized": false,
10
+ "rstrip": false,
11
+ "single_word": false,
12
+ "special": true
13
+ },
14
+ "1": {
15
+ "content": "<s>",
16
+ "lstrip": false,
17
+ "normalized": false,
18
+ "rstrip": false,
19
+ "single_word": false,
20
+ "special": true
21
+ },
22
+ "2": {
23
+ "content": "</s>",
24
+ "lstrip": false,
25
+ "normalized": false,
26
+ "rstrip": false,
27
+ "single_word": false,
28
+ "special": true
29
+ },
30
+ "32000": {
31
+ "content": "<fake_token_around_image>",
32
+ "lstrip": false,
33
+ "normalized": false,
34
+ "rstrip": false,
35
+ "single_word": false,
36
+ "special": true
37
+ },
38
+ "32001": {
39
+ "content": "<image>",
40
+ "lstrip": false,
41
+ "normalized": false,
42
+ "rstrip": false,
43
+ "single_word": false,
44
+ "special": true
45
+ },
46
+ "32002": {
47
+ "content": "<end_of_utterance>",
48
+ "lstrip": false,
49
+ "normalized": false,
50
+ "rstrip": false,
51
+ "single_word": false,
52
+ "special": true
53
+ },
54
+ "32003": {
55
+ "content": "<pad>",
56
+ "lstrip": false,
57
+ "normalized": false,
58
+ "rstrip": false,
59
+ "single_word": false,
60
+ "special": true
61
+ }
62
+ },
63
+ "additional_special_tokens": [
64
+ "<fake_token_around_image>",
65
+ "<image>",
66
+ "<end_of_utterance>"
67
+ ],
68
+ "bos_token": "<s>",
69
+ "clean_up_tokenization_spaces": false,
70
+ "do_image_splitting": false,
71
+ "eos_token": "</s>",
72
+ "legacy": false,
73
+ "model_max_length": 1000000000000000019884624838656,
74
+ "pad_token": "<pad>",
75
+ "processor_class": "Idefics2Processor",
76
+ "sp_model_kwargs": {},
77
+ "spaces_between_special_tokens": false,
78
+ "tokenizer_class": "LlamaTokenizer",
79
+ "unk_token": "<unk>",
80
+ "use_default_system_prompt": true
81
+ }