RaushanTurganbay HF staff commited on
Commit
657f531
1 Parent(s): 403c99b

Upload processor

Browse files
Files changed (2) hide show
  1. preprocessor_config.json +0 -17
  2. processor_config.json +4 -0
preprocessor_config.json CHANGED
@@ -1,21 +1,4 @@
1
  {
2
- "_valid_processor_keys": [
3
- "images",
4
- "do_resize",
5
- "size",
6
- "resample",
7
- "do_center_crop",
8
- "crop_size",
9
- "do_rescale",
10
- "rescale_factor",
11
- "do_normalize",
12
- "image_mean",
13
- "image_std",
14
- "do_convert_rgb",
15
- "return_tensors",
16
- "data_format",
17
- "input_data_format"
18
- ],
19
  "crop_size": {
20
  "height": 336,
21
  "width": 336
 
1
  {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
  "crop_size": {
3
  "height": 336,
4
  "width": 336
processor_config.json ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ {
2
+ "chat_template": "{% for message in messages %}{% if message['role'] == 'system' %}{{ message['content'][0]['text'] }}{% else %}{{ message['role'].upper() + ': '}}{% endif %}{# Render all images first #}{% for content in message['content'] | selectattr('type', 'equalto', 'image') %}{{ '<image>\n' }}{% endfor %}{# Render all text next #}{% for content in message['content'] | selectattr('type', 'equalto', 'text') %}{{ content['text'] + ' '}}{% endfor %}{% endfor %}{% if add_generation_prompt %}{{ 'ASSISTANT:' }}{% endif %}",
3
+ "processor_class": "LlavaProcessor"
4
+ }