Image-Text-to-Text
Transformers
Safetensors
English
gemma4
aerial-vlm
drone
uav
vision-language-model
aerial-imagery
scene-understanding
visual-question-answering
visual-grounding
robotics
edge-ai
structured-output
open-weights
miril
conversational
Instructions to use MirilAI/Miril-DroneVLM-2B-2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use MirilAI/Miril-DroneVLM-2B-2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="MirilAI/Miril-DroneVLM-2B-2") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("MirilAI/Miril-DroneVLM-2B-2") model = AutoModelForMultimodalLM.from_pretrained("MirilAI/Miril-DroneVLM-2B-2", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use MirilAI/Miril-DroneVLM-2B-2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "MirilAI/Miril-DroneVLM-2B-2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MirilAI/Miril-DroneVLM-2B-2", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/MirilAI/Miril-DroneVLM-2B-2
- SGLang
How to use MirilAI/Miril-DroneVLM-2B-2 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "MirilAI/Miril-DroneVLM-2B-2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MirilAI/Miril-DroneVLM-2B-2", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "MirilAI/Miril-DroneVLM-2B-2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "MirilAI/Miril-DroneVLM-2B-2", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use MirilAI/Miril-DroneVLM-2B-2 with Docker Model Runner:
docker model run hf.co/MirilAI/Miril-DroneVLM-2B-2
| <svg xmlns="http://www.w3.org/2000/svg" width="1280" height="1477" viewBox="0 0 1280 1477" role="img"> | |
| <rect width="1280" height="1477" fill="#070d12"/> | |
| <text x="58" y="62" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="30" font-weight="700">Miril-DroneVLM-2B-2 complete validation comparison</text> | |
| <text x="58" y="96" fill="#c8d0cb" font-family="Arial, sans-serif" font-size="16" font-weight="400">Same held-out visual cases across every response route. Higher is better.</text> | |
| <rect x="58" y="121" width="18" height="18" fill="#9aa6ad"/> | |
| <text x="85" y="136" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="15" font-weight="700">Merged BF16</text> | |
| <rect x="288" y="121" width="18" height="18" fill="#4af082"/> | |
| <text x="315" y="136" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="15" font-weight="700">CUDA bnb8</text> | |
| <rect x="518" y="121" width="18" height="18" fill="#5ac8fa"/> | |
| <text x="545" y="136" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="15" font-weight="700">CUDA bnb4</text> | |
| <rect x="748" y="121" width="18" height="18" fill="#ffd166"/> | |
| <text x="775" y="136" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="15" font-weight="700">MLX 8-bit</text> | |
| <rect x="978" y="121" width="18" height="18" fill="#ff8a65"/> | |
| <text x="1005" y="136" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="15" font-weight="700">MLX 4-bit</text> | |
| <text x="58" y="208" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Valid JSON</text> | |
| <text x="58" y="231" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Strict bare JSON objects</text> | |
| <rect x="360" y="184" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="184" width="759.5" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="198" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.9%</text> | |
| <rect x="360" y="209" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="209" width="757.9" height="16" fill="#4af082"/> | |
| <text x="1138" y="223" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.7%</text> | |
| <rect x="360" y="234" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="234" width="752.7" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="248" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.0%</text> | |
| <rect x="360" y="259" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="259" width="760.0" height="16" fill="#ffd166"/> | |
| <text x="1138" y="273" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">100.0%</text> | |
| <rect x="360" y="284" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="284" width="759.8" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="298" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">100.0%</text> | |
| <text x="58" y="351" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Schema valid</text> | |
| <text x="58" y="374" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Exact keys and allowed values</text> | |
| <rect x="360" y="327" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="327" width="759.5" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="341" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.9%</text> | |
| <rect x="360" y="352" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="352" width="757.5" height="16" fill="#4af082"/> | |
| <text x="1138" y="366" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.7%</text> | |
| <rect x="360" y="377" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="377" width="750.4" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="391" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">98.7%</text> | |
| <rect x="360" y="402" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="402" width="760.0" height="16" fill="#ffd166"/> | |
| <text x="1138" y="416" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">100.0%</text> | |
| <rect x="360" y="427" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="427" width="402.8" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="441" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">53.0%</text> | |
| <text x="58" y="494" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Route accuracy</text> | |
| <text x="58" y="517" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Correct type plus intent or action</text> | |
| <rect x="360" y="470" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="470" width="759.5" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="484" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.9%</text> | |
| <rect x="360" y="495" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="495" width="756.9" height="16" fill="#4af082"/> | |
| <text x="1138" y="509" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">99.6%</text> | |
| <rect x="360" y="520" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="520" width="749.1" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="534" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">98.6%</text> | |
| <rect x="360" y="545" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="545" width="760.0" height="16" fill="#ffd166"/> | |
| <text x="1138" y="559" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">100.0%</text> | |
| <rect x="360" y="570" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="570" width="404.4" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="584" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">53.2%</text> | |
| <text x="58" y="637" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Caption / answer F1</text> | |
| <text x="58" y="660" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Reference content overlap</text> | |
| <rect x="360" y="613" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="613" width="293.5" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="627" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">38.6%</text> | |
| <rect x="360" y="638" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="638" width="174.9" height="16" fill="#4af082"/> | |
| <text x="1138" y="652" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">23.0%</text> | |
| <rect x="360" y="663" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="663" width="282.5" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="677" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">37.2%</text> | |
| <rect x="360" y="688" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="688" width="287.1" height="16" fill="#ffd166"/> | |
| <text x="1138" y="702" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">37.8%</text> | |
| <rect x="360" y="713" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="713" width="270.2" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="727" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">35.6%</text> | |
| <text x="58" y="780" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Spatial status</text> | |
| <text x="58" y="803" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Target, coarse, absent, or ambiguous</text> | |
| <rect x="360" y="756" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="756" width="654.7" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="770" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">86.1%</text> | |
| <rect x="360" y="781" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="781" width="532.4" height="16" fill="#4af082"/> | |
| <text x="1138" y="795" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">70.1%</text> | |
| <rect x="360" y="806" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="806" width="606.6" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="820" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">79.8%</text> | |
| <rect x="360" y="831" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="831" width="648.6" height="16" fill="#ffd166"/> | |
| <text x="1138" y="845" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">85.3%</text> | |
| <rect x="360" y="856" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="856" width="629.5" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="870" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">82.8%</text> | |
| <text x="58" y="923" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Precise target retained</text> | |
| <text x="58" y="946" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Valid precise target when reference is precise</text> | |
| <rect x="360" y="899" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="899" width="544.6" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="913" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">71.7%</text> | |
| <rect x="360" y="924" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="924" width="461.6" height="16" fill="#4af082"/> | |
| <text x="1138" y="938" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">60.7%</text> | |
| <rect x="360" y="949" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="949" width="559.5" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="963" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">73.6%</text> | |
| <rect x="360" y="974" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="974" width="541.3" height="16" fill="#ffd166"/> | |
| <text x="1138" y="988" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">71.2%</text> | |
| <rect x="360" y="999" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="999" width="522.9" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="1013" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">68.8%</text> | |
| <text x="58" y="1066" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Point within 100</text> | |
| <text x="58" y="1089" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Distance on the 0-1000 coordinate plane</text> | |
| <rect x="360" y="1042" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1042" width="290.9" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="1056" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">38.3%</text> | |
| <rect x="360" y="1067" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1067" width="69.8" height="16" fill="#4af082"/> | |
| <text x="1138" y="1081" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">9.2%</text> | |
| <rect x="360" y="1092" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1092" width="258.6" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="1106" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">34.0%</text> | |
| <rect x="360" y="1117" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1117" width="255.5" height="16" fill="#ffd166"/> | |
| <text x="1138" y="1131" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">33.6%</text> | |
| <rect x="360" y="1142" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1142" width="211.0" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="1156" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">27.8%</text> | |
| <text x="58" y="1209" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">Coarse direction exact</text> | |
| <text x="58" y="1232" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">Correct 3x3 directional cell</text> | |
| <rect x="360" y="1185" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1185" width="261.4" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="1199" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">34.4%</text> | |
| <rect x="360" y="1210" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1210" width="86.0" height="16" fill="#4af082"/> | |
| <text x="1138" y="1224" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">11.3%</text> | |
| <rect x="360" y="1235" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1235" width="237.3" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="1249" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">31.2%</text> | |
| <rect x="360" y="1260" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1260" width="250.9" height="16" fill="#ffd166"/> | |
| <text x="1138" y="1274" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">33.0%</text> | |
| <rect x="360" y="1285" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1285" width="196.2" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="1299" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">25.8%</text> | |
| <text x="58" y="1352" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="17" font-weight="700">No-target discipline</text> | |
| <text x="58" y="1375" fill="#9ba7a1" font-family="Arial, sans-serif" font-size="12" font-weight="400">No coordinates when no target applies</text> | |
| <rect x="360" y="1328" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1328" width="732.1" height="16" fill="#9aa6ad"/> | |
| <text x="1138" y="1342" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">96.3%</text> | |
| <rect x="360" y="1353" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1353" width="708.9" height="16" fill="#4af082"/> | |
| <text x="1138" y="1367" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">93.3%</text> | |
| <rect x="360" y="1378" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1378" width="702.2" height="16" fill="#5ac8fa"/> | |
| <text x="1138" y="1392" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">92.4%</text> | |
| <rect x="360" y="1403" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1403" width="726.7" height="16" fill="#ffd166"/> | |
| <text x="1138" y="1417" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">95.6%</text> | |
| <rect x="360" y="1428" width="760" height="16" fill="#17232a"/> | |
| <rect x="360" y="1428" width="726.1" height="16" fill="#ff8a65"/> | |
| <text x="1138" y="1442" fill="#f4f7f5" font-family="Arial, sans-serif" font-size="14" font-weight="700">95.5%</text> | |
| </svg> | |