Views
No views yet
| Property | Value |
|---|---|
| Base Model | allenai/Molmo2-4B |
| Quantization | NVFP4 (4-bit floating point) |
| Format | nvfp4-pack-quantized (compressed-tensors) |
| Model Size | ~6.5GB (vs ~16GB original) |
| Vision Backbone | Full precision (not quantized) |
Important: This model requires a custom vLLM build with NVFP4 quantized weight mapping support for Molmo2.
1docker run -it --gpus all \
2 --entrypoint /bin/bash \
3 -e SETUPTOOLS_SCM_PRETEND_VERSION=0.9.0 \
4 -v /path/to/your/models:/workspace/models \
5 -p 8000:8000 \
6 vllm/vllm-openai:latest1git clone https://github.com/George-Polya/vllm.git -b dev/molmo2-quantize
2cd vllm
3pip install --no-build-isolation -e .1vllm serve /workspace/models/Molmo2-4B-NVFP4 \
2 --trust-remote-code \
3 --max-model-len 4096 \
4 --max-num-batched-tokens 81921from openai import OpenAI
2import base64
3
4client = OpenAI(base_url="http://localhost:8000/v1", api_key="EMPTY")
5
6# With image URL
7response = client.chat.completions.create(
8 model="Molmo2-4B-NVFP4",
9 messages=[
10 {
11 "role": "user",
12 "content": [
13 {"type": "image_url", "image_url": {"url": "https://example.com/image.jpg"}},
14 {"type": "text", "text": "Describe this image."}
15 ]
16 }
17 ],
18 max_tokens=512
19)
20print(response.choices[0].message.content)prefix parameter to vision layers for proper weight name mappinghf_to_vllm_mapper patterns for quantized weight names1default_stage:
2 default_modifiers:
3 QuantizationModifier:
4 targets: [Linear]
5 ignore: ['re:.*lm_head', 're:.*vision_backbone.*', 're:.*mlp.gate$']
6 scheme: NVFP4| FP8 | NVFP4 | |
|---|---|---|
| Bits | 8 | 4 |
| Size | ~8GB | ~6.5GB |
| Quality | Higher | Lower |
| Speed | Fast | Faster |