ariG23498 HF Staff commited on
Commit
3dce296
·
verified ·
1 Parent(s): 7d02b13

Upload nvidia_NVIDIA-Nemotron-Nano-12B-v2-VL-FP8_0.txt with huggingface_hub

Browse files
nvidia_NVIDIA-Nemotron-Nano-12B-v2-VL-FP8_0.txt ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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="nvidia/NVIDIA-Nemotron-Nano-12B-v2-VL-FP8")
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/.cache/uv/environments-v2/2bdff7a515a609ef/lib/python3.13/site-packages/transformers/dynamic_module_utils.py", line 757, in resolve_trust_remote_code
21
+ answer = input(
22
+ f"{error_message} You can inspect the repository content at https://hf.co/{model_name}.\n"
23
+ f"You can avoid this prompt in future by passing the argument `trust_remote_code=True`.\n\n"
24
+ f"Do you wish to run the custom code? [y/N] "
25
+ )
26
+ EOFError: EOF when reading a line
27
+
28
+ During handling of the above exception, another exception occurred:
29
+
30
+ Traceback (most recent call last):
31
+ File "/tmp/nvidia_NVIDIA-Nemotron-Nano-12B-v2-VL-FP8_0FB05xA.py", line 19, in <module>
32
+ pipe = pipeline("image-text-to-text", model="nvidia/NVIDIA-Nemotron-Nano-12B-v2-VL-FP8")
33
+ File "/tmp/.cache/uv/environments-v2/2bdff7a515a609ef/lib/python3.13/site-packages/transformers/pipelines/__init__.py", line 922, in pipeline
34
+ config = AutoConfig.from_pretrained(
35
+ model, _from_pipeline=task, code_revision=code_revision, **hub_kwargs, **model_kwargs
36
+ )
37
+ File "/tmp/.cache/uv/environments-v2/2bdff7a515a609ef/lib/python3.13/site-packages/transformers/models/auto/configuration_auto.py", line 1341, in from_pretrained
38
+ trust_remote_code = resolve_trust_remote_code(
39
+ trust_remote_code, pretrained_model_name_or_path, has_local_code, has_remote_code, upstream_repo
40
+ )
41
+ File "/tmp/.cache/uv/environments-v2/2bdff7a515a609ef/lib/python3.13/site-packages/transformers/dynamic_module_utils.py", line 769, in resolve_trust_remote_code
42
+ raise ValueError(
43
+ ...<2 lines>...
44
+ )
45
+ ValueError: The repository nvidia/NVIDIA-Nemotron-Nano-12B-v2-VL-FP8 contains custom code which must be executed to correctly load the model. You can inspect the repository content at https://hf.co/nvidia/NVIDIA-Nemotron-Nano-12B-v2-VL-FP8 .
46
+ You can inspect the repository content at https://hf.co/nvidia/NVIDIA-Nemotron-Nano-12B-v2-VL-FP8.
47
+ Please pass the argument `trust_remote_code=True` to allow custom code to be run.