Skip to content

Annotation d'images

Configurez l'annotation d'images dans Potato avec boîtes englobantes, polygones et étiquettes de classification. Zoom, déplacement, multi-étiquettes et pré-étiquetage assisté par IA sont pris en charge.

Potato prend en charge l'annotation d'images pour la classification, la détection d'objets et l'étiquetage de régions.

Activer l'affichage des images

yaml
image:
  enabled: true
  max_width: 800
  max_height: 600

Format des données

Référencez les images dans vos données :

json
{
  "id": "img_1",
  "image_path": "images/photo_001.jpg",
  "description": "Optional description"
}

Déclarez le champ image :

yaml
data_files:
  - path: data/image_tasks.json
    image_field: image_path

Classification d'images

Classer l'image entière :

yaml
annotation_schemes:
  - annotation_type: radio
    name: category
    description: "What is shown in this image?"
    labels:
      - Cat
      - Dog
      - Bird
      - Other
 
  - annotation_type: multiselect
    name: attributes
    description: "Select all that apply"
    labels:
      - Indoor
      - Outdoor
      - Multiple animals
      - Human present

Classification multi-étiquettes

yaml
annotation_schemes:
  - annotation_type: multiselect
    name: objects
    description: "What objects are visible?"
    labels:
      - Person
      - Car
      - Building
      - Tree
      - Animal
      - Furniture
      - Food
      - Electronic device

Évaluation de la qualité d'image

yaml
annotation_schemes:
  - annotation_type: likert
    name: quality
    description: "Overall image quality"
    size: 5
    min_label: "Very poor"
    max_label: "Excellent"
 
  - annotation_type: multiselect
    name: issues
    description: "Select any quality issues"
    labels:
      - Blurry
      - Overexposed
      - Underexposed
      - Noisy
      - Low resolution
      - Watermark visible

Annotation par boîtes englobantes

Tracer des boîtes autour des objets :

yaml
annotation_schemes:
  - annotation_type: image_annotation
    tools: [bbox]
    name: objects
    description: "Draw boxes around objects"
    labels:
      - Person
      - Car
      - Bicycle
      - Traffic sign

Sortie des boîtes englobantes

json
{
  "id": "img_1",
  "objects": [
    {
      "label": "Person",
      "x": 100,
      "y": 50,
      "width": 80,
      "height": 200
    },
    {
      "label": "Car",
      "x": 300,
      "y": 150,
      "width": 150,
      "height": 100
    }
  ]
}

Boîtes englobantes préchargées

Charger des annotations existantes pour relecture :

json
{
  "id": "img_1",
  "image_path": "images/photo_001.jpg",
  "predictions": [
    {"label": "Person", "x": 100, "y": 50, "width": 80, "height": 200, "confidence": 0.95}
  ]
}
yaml
annotation_schemes:
  - annotation_type: image_annotation
    tools: [bbox]
    name: objects

Annotation de régions et de polygones

Pour les régions non rectangulaires :

yaml
annotation_schemes:
  - annotation_type: image_annotation
    tools: [polygon]
    name: regions
    description: "Outline regions of interest"
    labels:
      - Building
      - Road
      - Vegetation
      - Water

Comparaison d'images

Comparer deux images :

yaml
data_files:
  - path: data/image_pairs.json
    item_a_field: image_original
    item_b_field: image_edited
 
annotation_schemes:
  - annotation_type: pairwise
    name: preference
    description: "Which image looks better?"
    labels:
      - label: "Original"
        value: "A"
      - label: "Edited"
        value: "B"
      - label: "Same"
        value: "tie"

Légendage d'images

yaml
annotation_schemes:
  - annotation_type: text
    name: caption
    description: "Write a caption for this image"
    rows: 4
    placeholder: "Describe what you see..."

Relecture de la qualité des légendes

yaml
data_files:
  - path: data/captions.json
    image_field: image_path
    text_field: generated_caption
 
annotation_schemes:
  - annotation_type: likert
    name: accuracy
    description: "How accurate is this caption?"
    size: 5
    min_label: "Very inaccurate"
    max_label: "Very accurate"
 
  - annotation_type: likert
    name: fluency
    description: "How natural is the language?"
    size: 5
    min_label: "Very awkward"
    max_label: "Very natural"
 
  - annotation_type: text
    name: improved_caption
    description: "Suggest a better caption (optional)"
    rows: 4

Options d'affichage

Dimensions de l'image

yaml
image:
  max_width: 800
  max_height: 600
  preserve_aspect_ratio: true

Commandes de zoom

yaml
image:
  zoom_enabled: true
  initial_zoom: fit  # 'fit', 'actual', or percentage

Mode plein écran

yaml
image:
  fullscreen_enabled: true

Modération de contenu

yaml
annotation_schemes:
  - annotation_type: radio
    name: safe_for_work
    description: "Is this image safe for work?"
    labels:
      - Safe
      - Questionable
      - Not Safe
 
  - annotation_type: multiselect
    name: violation_types
    description: "Select all violations (if any)"
    labels:
      - Violence
      - Adult content
      - Hate symbols
      - Graphic content
      - Spam/advertisement

Formats pris en charge

Les formats d'image courants sont acceptés :

  • JPEG/JPG
  • PNG
  • GIF
  • WebP
  • BMP
yaml
image:
  allowed_formats: ["jpg", "jpeg", "png", "webp"]

Exemple complet : relecture d'une détection d'objets

yaml
task_name: "Object Detection Verification"
 
image:
  enabled: true
  max_width: 1000
  zoom_enabled: true
 
data_files:
  - path: data/detections.json
    image_field: image_path
 
annotation_schemes:
  # Review pre-loaded predictions
  - annotation_type: image_annotation
    tools: [bbox]
    name: objects
    description: "Verify and correct object boxes"
    labels:
      - Person
      - Vehicle
      - Animal
      - Object
  # Overall assessment
  - annotation_type: radio
    name: prediction_quality
    description: "How accurate were the predictions?"
    labels:
      - All correct
      - Minor corrections needed
      - Major corrections needed
      - Mostly incorrect
 
  - annotation_type: number
    name: missed_objects
    description: "How many objects were missed?"
    min: 0
    max: 50
 
  - annotation_type: text
    name: notes
    description: "Any issues or comments?"
    rows: 4
    label_requirement:
      required: false

Conseils de performance

  1. Réduisez la taille des images - Redimensionnez les grandes images avant l'annotation
  2. JPEG pour les photos - Fichiers plus légers, chargement plus rapide
  3. PNG pour les graphiques - Meilleur rendu des schémas et captures d'écran
  4. Activez le chargement différé - Pour les gros jeux de données
  5. Pensez aux vignettes - Pour les aperçus dans les vues en liste
  6. Prétraitez de façon homogène - Normalisez tailles et formats