Downloads · 30 days
136
3% of all-time downloads
2imi9/gemma-4-E2B-it-NVFP4A16
gemma-4-E2B-it-NVFP4A16 is a image-text-to-text model from 2imi9. Use it for the image-text-to-text task on the model card, and read the license before you ship it in a product. It is set up for transformers. The card lists the license as apache-2.0.
- Base Model: google/gemma-4-E2B-it - Quantization: NVFP4A16 (4-bit NV floating point weights, 16-bit activations) - Quantization Tool: llm-compressor
Downloads · 30 days
136
3% of all-time downloads
All-time downloads
5K
Public
Parameters
4.7B
8.4 GB on disk
Likes
3
Public
Click a slice to open those files.
.safetensors8.3 GB · 100%
How the weights are stored.
BF163.6B · 77%
From the Hugging Face model README
This model is a weight-only NVFP4A16 quantized version of Google's Gemma 4 E2B instruction-tuned model. Weights are quantized to FP4 with per-group (group size 16) quantization using the NVIDIA FP4 format, while activations remain in FP16.
The following modules are kept in their original precision:
lm_headvision_tower)audio_tower)embed_vision)embed_audio)from transformers import AutoModelForImageTextToText, AutoProcessor
from llmcompressor import oneshot
from llmcompressor.modifiers.quantization import QuantizationModifier
MODEL_ID = "google/gemma-4-E2B-it"
model = AutoModelForImageTextToText.from_pretrained(MODEL_ID, dtype="auto")
recipe = QuantizationModifier(
targets="Linear",
scheme="NVFP4A16",
ignore=[
"lm_head",
"re:.*vision_tower.*",
"re:.*audio_tower.*",
"re:.*embed_vision.*",
"re:.*embed_audio.*",
],
)
oneshot(model=model, recipe=recipe)
model.save_pretrained("gemma-4-E2B-it-NVFP4A16", save_compressed=True)
Sample generation after quantization:
Prompt: Hello my name is
Response: Hello! It's nice to meet you. What is your name?