Image-Text-to-Text
Keras
PyTorch
JAX
TensorFlow
English
zeromodels
qwen3_vl
qwen3-vl
multimodal
vision
Instructions to use zeromodels/qwen3-vl-8b-thinking with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Keras
How to use zeromodels/qwen3-vl-8b-thinking with Keras:
# Available backend options are: "jax", "torch", "tensorflow". import os os.environ["KERAS_BACKEND"] = "jax" import keras model = keras.saving.load_model("hf://zeromodels/qwen3-vl-8b-thinking") - Notebooks
- Google Colab
- Kaggle
Migrate to zeromodels (rename kf_*.json -> zm_*.json, fix refs in config + README, ensure tag + badge)
Browse files- README.md +20 -20
- kf_config.json → zm_config.json +3 -3
- kf_preprocessor.json → zm_preprocessor.json +21 -21
README.md
CHANGED
|
@@ -2,12 +2,12 @@
|
|
| 2 |
pipeline_tag: image-text-to-text
|
| 3 |
license: apache-2.0
|
| 4 |
base_model: Qwen/Qwen3-VL-8B-Thinking
|
| 5 |
-
library_name:
|
| 6 |
language:
|
| 7 |
- en
|
| 8 |
tags:
|
| 9 |
- keras
|
| 10 |
-
-
|
| 11 |
- qwen3_vl
|
| 12 |
- qwen3-vl
|
| 13 |
- multimodal
|
|
@@ -20,11 +20,11 @@ tags:
|
|
| 20 |
|
| 21 |
# Run Qwen3-VL with Keras 3: JAX, PyTorch, or TensorFlow
|
| 22 |
|
| 23 |
-
[ for [
|
| 28 |
|
| 29 |
For model details, license, and usage terms, see the upstream [model card](https://huggingface.co/Qwen/Qwen3-VL-8B-Thinking).
|
| 30 |
|
|
@@ -44,10 +44,10 @@ Paper: [Qwen-VL: A Frontier Large Vision-Language Model with Versatile Abilities
|
|
| 44 |
import os
|
| 45 |
os.environ["KERAS_BACKEND"] = "torch" # or "jax" / "tensorflow"
|
| 46 |
|
| 47 |
-
from
|
| 48 |
|
| 49 |
-
model = Qwen3VLTextGenerate.from_weights("
|
| 50 |
-
processor = Qwen3VLProcessor.from_weights("
|
| 51 |
|
| 52 |
inputs = processor(conversation=[
|
| 53 |
{"role": "user", "content": [{"type": "text", "text": "Hello, who are you?"}]}
|
|
@@ -63,10 +63,10 @@ import os
|
|
| 63 |
os.environ["KERAS_BACKEND"] = "torch" # or "jax" / "tensorflow"
|
| 64 |
|
| 65 |
from PIL import Image
|
| 66 |
-
from
|
| 67 |
|
| 68 |
-
model = Qwen3VLConditionalGenerate.from_weights("
|
| 69 |
-
processor = Qwen3VLProcessor.from_weights("
|
| 70 |
|
| 71 |
inputs = processor(conversation=[
|
| 72 |
{"role": "user", "content": [
|
|
@@ -78,18 +78,18 @@ outputs = model.generate(**inputs, max_new_tokens=64)
|
|
| 78 |
print(processor.decode(outputs[0]))
|
| 79 |
```
|
| 80 |
|
| 81 |
-
Load any Qwen3-VL variant the same way with `from_weights("
|
| 82 |
|
| 83 |
| Variant | Hub |
|
| 84 |
| --- | --- |
|
| 85 |
-
| `qwen3-vl-2b-instruct` | [
|
| 86 |
-
| `qwen3-vl-2b-thinking` | [
|
| 87 |
-
| `qwen3-vl-4b-instruct` | [
|
| 88 |
-
| `qwen3-vl-4b-thinking` | [
|
| 89 |
-
| `qwen3-vl-8b-instruct` | [
|
| 90 |
-
| `qwen3-vl-8b-thinking` | [
|
| 91 |
-
| `qwen3-vl-32b-instruct` | [
|
| 92 |
-
| `qwen3-vl-32b-thinking` | [
|
| 93 |
|
| 94 |
## Special Thanks
|
| 95 |
|
|
|
|
| 2 |
pipeline_tag: image-text-to-text
|
| 3 |
license: apache-2.0
|
| 4 |
base_model: Qwen/Qwen3-VL-8B-Thinking
|
| 5 |
+
library_name: zeromodels
|
| 6 |
language:
|
| 7 |
- en
|
| 8 |
tags:
|
| 9 |
- keras
|
| 10 |
+
- zeromodels
|
| 11 |
- qwen3_vl
|
| 12 |
- qwen3-vl
|
| 13 |
- multimodal
|
|
|
|
| 20 |
|
| 21 |
# Run Qwen3-VL with Keras 3: JAX, PyTorch, or TensorFlow
|
| 22 |
|
| 23 |
+
[](https://github.com/IMvision12/ZeroModels) [](https://imvision12.github.io/ZeroModels/qwen3_vl/) [](https://huggingface.co/collections/zeromodels/qwen3-vl-6a7d7677c2926ecbddb1ed0a)
|
| 24 |
|
| 25 |
+
# zeromodels/qwen3-vl-8b-thinking
|
| 26 |
|
| 27 |
+
Pure-**Keras 3** conversion of [`Qwen/Qwen3-VL-8B-Thinking`](https://huggingface.co/Qwen/Qwen3-VL-8B-Thinking) for [zeromodels](https://github.com/IMvision12/ZeroModels). One implementation runs unmodified on **TensorFlow / Torch / JAX**. This is the **8B** variant, served here as **image + text -> text** via `Qwen3VLProcessor`; weights are stored in **bfloat16**.
|
| 28 |
|
| 29 |
For model details, license, and usage terms, see the upstream [model card](https://huggingface.co/Qwen/Qwen3-VL-8B-Thinking).
|
| 30 |
|
|
|
|
| 44 |
import os
|
| 45 |
os.environ["KERAS_BACKEND"] = "torch" # or "jax" / "tensorflow"
|
| 46 |
|
| 47 |
+
from zeromodels.models.qwen3_vl import Qwen3VLTextGenerate, Qwen3VLProcessor
|
| 48 |
|
| 49 |
+
model = Qwen3VLTextGenerate.from_weights("zeromodels/qwen3-vl-8b-thinking")
|
| 50 |
+
processor = Qwen3VLProcessor.from_weights("zeromodels/qwen3-vl-8b-thinking")
|
| 51 |
|
| 52 |
inputs = processor(conversation=[
|
| 53 |
{"role": "user", "content": [{"type": "text", "text": "Hello, who are you?"}]}
|
|
|
|
| 63 |
os.environ["KERAS_BACKEND"] = "torch" # or "jax" / "tensorflow"
|
| 64 |
|
| 65 |
from PIL import Image
|
| 66 |
+
from zeromodels.models.qwen3_vl import Qwen3VLConditionalGenerate, Qwen3VLProcessor
|
| 67 |
|
| 68 |
+
model = Qwen3VLConditionalGenerate.from_weights("zeromodels/qwen3-vl-8b-thinking")
|
| 69 |
+
processor = Qwen3VLProcessor.from_weights("zeromodels/qwen3-vl-8b-thinking")
|
| 70 |
|
| 71 |
inputs = processor(conversation=[
|
| 72 |
{"role": "user", "content": [
|
|
|
|
| 78 |
print(processor.decode(outputs[0]))
|
| 79 |
```
|
| 80 |
|
| 81 |
+
Load any Qwen3-VL variant the same way with `from_weights("zeromodels/<variant>")`:
|
| 82 |
|
| 83 |
| Variant | Hub |
|
| 84 |
| --- | --- |
|
| 85 |
+
| `qwen3-vl-2b-instruct` | [zeromodels/qwen3-vl-2b-instruct](https://huggingface.co/zeromodels/qwen3-vl-2b-instruct) |
|
| 86 |
+
| `qwen3-vl-2b-thinking` | [zeromodels/qwen3-vl-2b-thinking](https://huggingface.co/zeromodels/qwen3-vl-2b-thinking) |
|
| 87 |
+
| `qwen3-vl-4b-instruct` | [zeromodels/qwen3-vl-4b-instruct](https://huggingface.co/zeromodels/qwen3-vl-4b-instruct) |
|
| 88 |
+
| `qwen3-vl-4b-thinking` | [zeromodels/qwen3-vl-4b-thinking](https://huggingface.co/zeromodels/qwen3-vl-4b-thinking) |
|
| 89 |
+
| `qwen3-vl-8b-instruct` | [zeromodels/qwen3-vl-8b-instruct](https://huggingface.co/zeromodels/qwen3-vl-8b-instruct) |
|
| 90 |
+
| `qwen3-vl-8b-thinking` | [zeromodels/qwen3-vl-8b-thinking](https://huggingface.co/zeromodels/qwen3-vl-8b-thinking) |
|
| 91 |
+
| `qwen3-vl-32b-instruct` | [zeromodels/qwen3-vl-32b-instruct](https://huggingface.co/zeromodels/qwen3-vl-32b-instruct) |
|
| 92 |
+
| `qwen3-vl-32b-thinking` | [zeromodels/qwen3-vl-32b-thinking](https://huggingface.co/zeromodels/qwen3-vl-32b-thinking) |
|
| 93 |
|
| 94 |
## Special Thanks
|
| 95 |
|
kf_config.json → zm_config.json
RENAMED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
{
|
| 2 |
-
"library_name": "
|
| 3 |
-
"
|
| 4 |
-
"model_module": "
|
| 5 |
"model_class": "Qwen3VLConditionalGenerate",
|
| 6 |
"variant": "qwen3-vl-8b-thinking",
|
| 7 |
"weights": "model.weights.json",
|
|
|
|
| 1 |
{
|
| 2 |
+
"library_name": "zeromodels",
|
| 3 |
+
"zeromodels_version": "1.2.2",
|
| 4 |
+
"model_module": "zeromodels.models.qwen3_vl",
|
| 5 |
"model_class": "Qwen3VLConditionalGenerate",
|
| 6 |
"variant": "qwen3-vl-8b-thinking",
|
| 7 |
"weights": "model.weights.json",
|
kf_preprocessor.json → zm_preprocessor.json
RENAMED
|
@@ -1,22 +1,22 @@
|
|
| 1 |
-
{
|
| 2 |
-
"library_name": "
|
| 3 |
-
"
|
| 4 |
-
"preprocessor_module": "
|
| 5 |
-
"preprocessor_class": "Qwen2VLImageProcessor",
|
| 6 |
-
"variant": "qwen3-vl-8b-thinking",
|
| 7 |
-
"patch_size": 14,
|
| 8 |
-
"spatial_merge_size": 2,
|
| 9 |
-
"temporal_patch_size": 2,
|
| 10 |
-
"min_pixels": 3136,
|
| 11 |
-
"max_pixels": 1003520,
|
| 12 |
-
"image_mean": [
|
| 13 |
-
0.5,
|
| 14 |
-
0.5,
|
| 15 |
-
0.5
|
| 16 |
-
],
|
| 17 |
-
"image_std": [
|
| 18 |
-
0.5,
|
| 19 |
-
0.5,
|
| 20 |
-
0.5
|
| 21 |
-
]
|
| 22 |
}
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"library_name": "zeromodels",
|
| 3 |
+
"zeromodels_version": "1.2.2",
|
| 4 |
+
"preprocessor_module": "zeromodels.models.qwen2_vl",
|
| 5 |
+
"preprocessor_class": "Qwen2VLImageProcessor",
|
| 6 |
+
"variant": "qwen3-vl-8b-thinking",
|
| 7 |
+
"patch_size": 14,
|
| 8 |
+
"spatial_merge_size": 2,
|
| 9 |
+
"temporal_patch_size": 2,
|
| 10 |
+
"min_pixels": 3136,
|
| 11 |
+
"max_pixels": 1003520,
|
| 12 |
+
"image_mean": [
|
| 13 |
+
0.5,
|
| 14 |
+
0.5,
|
| 15 |
+
0.5
|
| 16 |
+
],
|
| 17 |
+
"image_std": [
|
| 18 |
+
0.5,
|
| 19 |
+
0.5,
|
| 20 |
+
0.5
|
| 21 |
+
]
|
| 22 |
}
|