Upload ServiceNow-AI_Apriel-1.6-15b-Thinker_0.txt with huggingface_hub
Browse files
ServiceNow-AI_Apriel-1.6-15b-Thinker_0.txt
CHANGED
|
@@ -1 +1,59 @@
|
|
| 1 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 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="ServiceNow-AI/Apriel-1.6-15b-Thinker")
|
| 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/ServiceNow-AI_Apriel-1.6-15b-Thinker_0RmGtKg.py", line 26, in <module>
|
| 21 |
+
pipe = pipeline("image-text-to-text", model="ServiceNow-AI/Apriel-1.6-15b-Thinker")
|
| 22 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/transformers/pipelines/__init__.py", line 1229, in pipeline
|
| 23 |
+
return pipeline_class(model=model, framework=framework, task=task, **kwargs)
|
| 24 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/transformers/pipelines/image_text_to_text.py", line 191, in __init__
|
| 25 |
+
super().__init__(*args, **kwargs)
|
| 26 |
+
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
|
| 27 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/transformers/pipelines/base.py", line 1044, in __init__
|
| 28 |
+
self.model.to(self.device)
|
| 29 |
+
~~~~~~~~~~~~~^^^^^^^^^^^^^
|
| 30 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/transformers/modeling_utils.py", line 4343, in to
|
| 31 |
+
return super().to(*args, **kwargs)
|
| 32 |
+
~~~~~~~~~~^^^^^^^^^^^^^^^^^
|
| 33 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/torch/nn/modules/module.py", line 1371, in to
|
| 34 |
+
return self._apply(convert)
|
| 35 |
+
~~~~~~~~~~~^^^^^^^^^
|
| 36 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/torch/nn/modules/module.py", line 930, in _apply
|
| 37 |
+
module._apply(fn)
|
| 38 |
+
~~~~~~~~~~~~~^^^^
|
| 39 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/torch/nn/modules/module.py", line 930, in _apply
|
| 40 |
+
module._apply(fn)
|
| 41 |
+
~~~~~~~~~~~~~^^^^
|
| 42 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/torch/nn/modules/module.py", line 930, in _apply
|
| 43 |
+
module._apply(fn)
|
| 44 |
+
~~~~~~~~~~~~~^^^^
|
| 45 |
+
[Previous line repeated 3 more times]
|
| 46 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/torch/nn/modules/module.py", line 957, in _apply
|
| 47 |
+
param_applied = fn(param)
|
| 48 |
+
File "/tmp/.cache/uv/environments-v2/10e48a7117c25b66/lib/python3.13/site-packages/torch/nn/modules/module.py", line 1357, in convert
|
| 49 |
+
return t.to(
|
| 50 |
+
~~~~^
|
| 51 |
+
device,
|
| 52 |
+
^^^^^^^
|
| 53 |
+
dtype if t.is_floating_point() or t.is_complex() else None,
|
| 54 |
+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
| 55 |
+
non_blocking,
|
| 56 |
+
^^^^^^^^^^^^^
|
| 57 |
+
)
|
| 58 |
+
^
|
| 59 |
+
torch.OutOfMemoryError: CUDA out of memory. Tried to allocate 140.00 MiB. GPU 0 has a total capacity of 22.30 GiB of which 88.69 MiB is free. Process 26244 has 22.21 GiB memory in use. Of the allocated memory 21.96 GiB is allocated by PyTorch, and 126.00 KiB is reserved by PyTorch but unallocated. If reserved but unallocated memory is large try setting PYTORCH_CUDA_ALLOC_CONF=expandable_segments:True to avoid fragmentation. See documentation for Memory Management (https://pytorch.org/docs/stable/notes/cuda.html#environment-variables)
|