Image-Text-to-Text
MLX
Safetensors
English
qwen2_vl
vision-language
image-to-text
qwen2-vl
apple-silicon
conversational
8-bit precision
Instructions to use Munchit/dam-vision-v3-mlx with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use Munchit/dam-vision-v3-mlx with MLX:
# Make sure mlx-vlm is installed # pip install --upgrade mlx-vlm from mlx_vlm import load, generate from mlx_vlm.prompt_utils import apply_chat_template from mlx_vlm.utils import load_config # Load the model model, processor = load("Munchit/dam-vision-v3-mlx") config = load_config("Munchit/dam-vision-v3-mlx") # Prepare input image = ["http://images.cocodataset.org/val2017/000000039769.jpg"] prompt = "Describe this image." # Apply chat template formatted_prompt = apply_chat_template( processor, config, prompt, num_images=1 ) # Generate output output = generate(model, processor, formatted_prompt, image) print(output) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
| { | |
| "architectures": [ | |
| "Qwen2VLForConditionalGeneration" | |
| ], | |
| "attention_dropout": 0.0, | |
| "bos_token_id": 151643, | |
| "eos_token_id": [ | |
| 151645, | |
| 151643 | |
| ], | |
| "hidden_act": "silu", | |
| "hidden_size": 1536, | |
| "image_token_id": 151655, | |
| "initializer_range": 0.02, | |
| "intermediate_size": 8960, | |
| "max_position_embeddings": 32768, | |
| "max_window_layers": 28, | |
| "model_type": "qwen2_vl", | |
| "num_attention_heads": 12, | |
| "num_hidden_layers": 28, | |
| "num_key_value_heads": 2, | |
| "quantization": { | |
| "group_size": 64, | |
| "bits": 8, | |
| "mode": "affine" | |
| }, | |
| "quantization_config": { | |
| "group_size": 64, | |
| "bits": 8, | |
| "mode": "affine" | |
| }, | |
| "rms_norm_eps": 1e-06, | |
| "rope_scaling": { | |
| "type": "mrope", | |
| "mrope_section": [ | |
| 16, | |
| 24, | |
| 24 | |
| ] | |
| }, | |
| "rope_theta": 1000000.0, | |
| "sliding_window": 32768, | |
| "tie_word_embeddings": true, | |
| "transformers_version": "4.41.2", | |
| "use_cache": true, | |
| "use_sliding_window": false, | |
| "video_token_id": 151656, | |
| "vision_config": { | |
| "depth": 32, | |
| "embed_dim": 1280, | |
| "mlp_ratio": 4, | |
| "num_heads": 16, | |
| "in_chans": 3, | |
| "hidden_size": 1536, | |
| "patch_size": 14, | |
| "spatial_merge_size": 2, | |
| "spatial_patch_size": 14, | |
| "temporal_patch_size": 2 | |
| }, | |
| "vision_end_token_id": 151653, | |
| "vision_start_token_id": 151652, | |
| "vision_token_id": 151654, | |
| "vocab_size": 151936 | |
| } |