Agent skill · research science · sickn33

hugging-face-vision-trainer

Train object detection, image classification, and SAM or SAM2 segmentation models locally or on Hugging Face Jobs, with dataset validation and results saved to the Hub.

Why this skill is useful

Provides specific commands and structured dataset requirements for training vision models that the AI wouldn't reliably generate on its own.

What it needs

Requires hugging-face account access. About 3k tokens when loaded. Last updated 2026-08-07. 44,571 stars on the source repository.

What this skill does

Vision Model Training on Hugging Face Jobs Train object detection, image classification, and SAM/SAM2 segmentation models on managed cloud GPUs. No local GPU setup required—results are automatically saved to the Hugging Face Hub. Detailed Guide Read the detailed guide before executing this skill. It retains the complete procedure and reference material. Treat its safety, prerequisites, and validation requirements as mandatory. For focused work, load the relevant sections; for end-to-end work, read the guide completely. When to Use This Skill Use this skill when users want to: Fine-tune object detection models (D-FINE, RT-DETR v2, DETR, YOLOS) on cloud GPUs or local Fine-tune image classification models (timm: MobileNetV3, MobileViT, ResNet, ViT/DINOv3, or any Transformers classifier) on cloud GPUs or local Fine-tune SAM or SAM2 models for segmentation / image matting using bbox or point prompts Train bounding-box detectors on custom datasets Train image classifiers on custom datasets Train segmentation models on custom mask datasets with prompts Run vision training jobs on Hugging Face Jobs infrastructure Ensure trained vision models are permanently saved to the Hub Prerequisites Checklist Before starting any training job, verify: Account & Authentication Hugging Face Account with Pro, Team, or Enterprise plan (Jobs require paid plan) Authenticated login: Check with hfwhoami() (tool) or hf auth whoami (terminal) Token has write permissions MUST pass token in job secrets — see directive #3 below for syntax (MCP tool vs Python API) Dataset Requirements — Object Detection Dataset must exist on Hub Annotations must use the objects column with bbox, category (and optionally area) sub-fields Bboxes can be in xywh (COCO) or xyxy (Pascal VOC) format — auto-detected and converted Categories can be integers or strings — strings are auto-remapped to integer IDs imageid column is optional — generated automatically if missing ALWAYS validate unknown datasets before GPU training …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills sickn33/hugging-face-vision-trainer--2359f4

View the source on GitHub

Browse the @skills marketplace