docker.recipes

Label Studio

beginner

Data labeling tool for ML projects.

Overview

Label Studio is an open-source data labeling platform developed by HumanSignal that enables teams to annotate various types of data for machine learning projects. Originally launched in 2019, it has become one of the most popular solutions for creating high-quality training datasets, supporting annotation workflows for images, text, audio, video, HTML, and time series data with over 50 pre-built labeling templates. This Docker deployment leverages the official heartexlabs/label-studio image with local file serving capabilities enabled, allowing users to annotate data stored directly on their filesystem. The configuration mounts a local files directory into the container and uses persistent volumes for project data, enabling efficient data labeling workflows without requiring external cloud storage or complex file management systems. Data scientists, ML engineers, and research teams who need to create annotated datasets for computer vision, natural language processing, or audio analysis projects will find this setup particularly valuable. The containerized deployment eliminates installation complexities while providing immediate access to Label Studio's collaborative annotation interface, export capabilities to popular ML formats like COCO and YOLO, and integration options for ML-assisted labeling workflows.

Key Features

  • Multi-format data annotation support including images, text, audio, video, HTML and time series data
  • Over 50 pre-built labeling templates for common ML tasks like object detection, classification, and NER
  • Local file serving capability for annotating data stored on the host filesystem
  • Export functionality to popular ML formats including COCO, YOLO, Pascal VOC, JSON, and CSV
  • Web-based collaborative interface supporting multiple annotators with role-based access control
  • ML backend integration for automated pre-annotations and active learning workflows
  • Project-based organization with customizable labeling interfaces and validation rules
  • Annotation statistics and progress tracking for managing large-scale labeling projects

Common Use Cases

  • 1Computer vision teams creating object detection datasets for autonomous vehicle or surveillance systems
  • 2NLP researchers annotating text corpora for sentiment analysis, named entity recognition, or classification tasks
  • 3Audio processing teams labeling speech datasets for voice recognition or music analysis applications
  • 4Medical imaging projects requiring annotation of X-rays, MRIs, or pathology slides for diagnostic AI models
  • 5Content moderation teams creating training data for automated content classification systems
  • 6Academic research groups conducting annotation studies with multiple human labelers and inter-annotator agreement analysis
  • 7Startups building custom ML models who need cost-effective annotation tools without enterprise licensing fees

Prerequisites

  • Docker Engine 20.10+ and Docker Compose v2.0+ installed on the host system
  • Minimum 2GB RAM available for the Label Studio container during active annotation sessions
  • Port 8080 available on the host system for the Label Studio web interface
  • Local storage space for datasets in the ./files directory and persistent volume data
  • Basic understanding of machine learning annotation concepts and export formats
  • Web browser with JavaScript enabled for accessing the annotation interface

For development & testing. Review security settings, change default credentials, and test thoroughly before production use. See Terms

docker-compose.yml

docker-compose.yml
1services:
2 label-studio:
3 image: heartexlabs/label-studio:latest
4 container_name: label-studio
5 restart: unless-stopped
6 environment:
7 LABEL_STUDIO_LOCAL_FILES_SERVING_ENABLED: "true"
8 LABEL_STUDIO_LOCAL_FILES_DOCUMENT_ROOT: /label-studio/files
9 volumes:
10 - label_studio_data:/label-studio/data
11 - ./files:/label-studio/files
12 ports:
13 - "8080:8080"
14
15volumes:
16 label_studio_data:

.env Template

.env
1# Mount your data files in ./files

Usage Notes

  1. 1Docs: https://labelstud.io/guide/
  2. 2Access at http://localhost:8080 - create account on first visit
  3. 3Supports labeling for images, text, audio, video, HTML, time series
  4. 4Create labeling templates or use 50+ pre-built templates
  5. 5Export to COCO, YOLO, Pascal VOC, JSON, CSV formats
  6. 6ML backend integration for pre-annotations and active learning

Quick Start

terminal
1# 1. Create the compose file
2cat > docker-compose.yml << 'EOF'
3services:
4 label-studio:
5 image: heartexlabs/label-studio:latest
6 container_name: label-studio
7 restart: unless-stopped
8 environment:
9 LABEL_STUDIO_LOCAL_FILES_SERVING_ENABLED: "true"
10 LABEL_STUDIO_LOCAL_FILES_DOCUMENT_ROOT: /label-studio/files
11 volumes:
12 - label_studio_data:/label-studio/data
13 - ./files:/label-studio/files
14 ports:
15 - "8080:8080"
16
17volumes:
18 label_studio_data:
19EOF
20
21# 2. Create the .env file
22cat > .env << 'EOF'
23# Mount your data files in ./files
24EOF
25
26# 3. Start the services
27docker compose up -d
28
29# 4. View logs
30docker compose logs -f

One-Liner

Run this command to download and set up the recipe in one step:

terminal
1curl -fsSL https://docker.recipes/api/recipes/label-studio/run | bash

Troubleshooting

  • Permission denied when accessing files: Ensure the ./files directory has proper read/write permissions for the container user (UID 1001)
  • Label Studio interface not loading: Check that port 8080 isn't blocked by firewall and the container logs don't show binding errors
  • Import tasks failing with file not found: Verify files are placed in the ./files directory and use relative paths when importing data
  • Container exits with database migration errors: Remove the label_studio_data volume and restart to reinitialize the database
  • Annotations not saving or disappearing: Check available disk space for Docker volumes and ensure the container has write permissions
  • Large file uploads timing out: Increase Docker's memory limits and consider using local file import instead of web upload for files >100MB

Community Notes

Loading...
Loading notes...

Download Recipe Kit

Get all files in a ready-to-deploy package

Includes docker-compose.yml, .env template, README, and license

Ad Space