ariG23498 HF Staff commited on
Commit
863f951
·
verified ·
1 Parent(s): 322d8c8

Upload Qwen_Qwen3.5-0.8B-Base_0.txt with huggingface_hub

Browse files
Files changed (1) hide show
  1. Qwen_Qwen3.5-0.8B-Base_0.txt +45 -0
Qwen_Qwen3.5-0.8B-Base_0.txt ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ```CODE:
2
+ # Use a pipeline as a high-level helper
3
+ from transformers import pipeline
4
+
5
+ pipe = pipeline("image-text-to-text", model="Qwen/Qwen3.5-0.8B-Base")
6
+ messages = [
7
+ {
8
+ "role": "user",
9
+ "content": [
10
+ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"},
11
+ {"type": "text", "text": "What animal is on the candy?"}
12
+ ]
13
+ },
14
+ ]
15
+ pipe(text=messages)
16
+ ```
17
+
18
+ ERROR:
19
+ Traceback (most recent call last):
20
+ File "/tmp/Qwen_Qwen3.5-0.8B-Base_0u0Qthz.py", line 36, in <module>
21
+ pipe(text=messages)
22
+ ~~~~^^^^^^^^^^^^^^^
23
+ File "/tmp/.cache/uv/environments-v2/4d21186f86769e23/lib/python3.13/site-packages/transformers/pipelines/image_text_to_text.py", line 283, in __call__
24
+ return super().__call__(Chat(text), **kwargs)
25
+ ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
26
+ File "/tmp/.cache/uv/environments-v2/4d21186f86769e23/lib/python3.13/site-packages/transformers/pipelines/base.py", line 1267, in __call__
27
+ return self.run_single(inputs, preprocess_params, forward_params, postprocess_params)
28
+ ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
29
+ File "/tmp/.cache/uv/environments-v2/4d21186f86769e23/lib/python3.13/site-packages/transformers/pipelines/base.py", line 1273, in run_single
30
+ model_inputs = self.preprocess(inputs, **preprocess_params)
31
+ File "/tmp/.cache/uv/environments-v2/4d21186f86769e23/lib/python3.13/site-packages/transformers/pipelines/image_text_to_text.py", line 330, in preprocess
32
+ model_inputs = self.processor.apply_chat_template(
33
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
34
+ inputs.messages,
35
+ ^^^^^^^^^^^^^^^^
36
+ ...<4 lines>...
37
+ return_dict=True,
38
+ ^^^^^^^^^^^^^^^^^
39
+ ).to(dtype=self.dtype)
40
+ ^
41
+ File "/tmp/.cache/uv/environments-v2/4d21186f86769e23/lib/python3.13/site-packages/transformers/processing_utils.py", line 1666, in apply_chat_template
42
+ raise ValueError(
43
+ "Cannot use apply_chat_template because this processor does not have a chat template."
44
+ )
45
+ ValueError: Cannot use apply_chat_template because this processor does not have a chat template.