Dedicated Endpoints
Run this model inference on single tenant GPU with unmatched speed and reliability at scale.
Container
Run this model inference with full control and performance in your environment.
Get help setting up a custom Dedicated Endpoints.
Talk with our engineer to get a quote for reserved GPU instances with discounts.
README
License: apache-2.0Metrics (Test Set)
| Metric | Value |
|---|---|
| Accuracy | 78.1% |
| Weighted F1 | 0.74 |
| Macro F1 | 0.45 |
| No DR F1 | 0.955 |
| Moderate F1 | 0.708 |
| Avg Latency (GPU) | 1.16s |
Usage
python
from transformers import Qwen2_5_VLForConditionalGeneration, AutoProcessorimport torchmodel = Qwen2_5_VLForConditionalGeneration.from_pretrained("ottokevin/JUSTCSL-OphthaVision-3B",torch_dtype=torch.bfloat16,device_map="auto",)processor = AutoProcessor.from_pretrained("ottokevin/JUSTCSL-OphthaVision-3B")# Prepare image + promptfrom PIL import Imageimage = Image.open("retina.png").convert("RGB")messages = [{"role": "user","content": [{"type": "image", "image": image},{"type": "text", "text": "Classify this retina image: 0=No DR, 1=Mild, 2=Moderate, 3=Severe, 4=Proliferative DR. Answer:"},],},]text = processor.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)inputs = processor(text=[text], images=[image], padding=True, return_tensors="pt").to(model.device)generated = model.generate(**inputs, max_new_tokens=8, do_sample=False)response = processor.tokenizer.decode(generated[0][inputs["input_ids"].shape[1]:], skip_special_tokens=True)print(response)
Model provider
ottokevin
Model tree
Base
Qwen/Qwen2.5-VL-3B-Instruct
Fine-tuned
this model
Modalities
Input
Text, Image
Output
Text
Pricing
Dedicated Endpoints
View detailsSupported Functionality
Model APIs
Dedicated Endpoints
Container
More information