dermora-dinov2-vit-b-skin
1
license:mit
by
rachitgoyell
Image Model
OTHER
New
0 downloads
Early-stage
Edge AI:
Mobile
Laptop
Server
Unknown
Mobile
Laptop
Server
Quick Summary
AI model with specialized capabilities.
Code Examples
Batch Inferencepython
from PIL import Image
images = [
Image.open("sample1.jpg").convert("RGB"),
Image.open("sample2.jpg").convert("RGB"),
Image.open("sample3.jpg").convert("RGB"),
]
inputs = processor(images=images, return_tensors="pt")
with torch.no_grad():
outputs = model(**inputs)
predicted_classes = outputs.logits.argmax(-1).tolist()
for idx, pred in enumerate(predicted_classes):
print(f"Image {idx + 1}: {model.config.id2label[pred]}")Extracting Features (without classification head)pythontransformers
from transformers import AutoModel
feature_extractor = AutoModel.from_pretrained(
"rachitgoyell/dermora-dinov2-vit-b-skin"
)
with torch.no_grad():
features = feature_extractor(**inputs)
cls_embedding = features.last_hidden_state[:, 0, :] # CLS token
print("Feature shape:", cls_embedding.shape) # (batch, 768)Deploy This Model
Production-ready deployment in minutes
Together.ai
Instant API access to this model
Production-ready inference API. Start free, scale to millions.
Try Free APIReplicate
One-click model deployment
Run models in the cloud with simple API. No DevOps required.
Deploy NowDisclosure: We may earn a commission from these partners. This helps keep LLMYourWay free.