How humansignal/labelimg works
LabelImg is a desktop Qt application for drawing object bounding boxes on images and saving annotations in PASCAL VOC, YOLO, or CreateML formats. The main workflow is launch, open an image or directory, create and edit labeled rectangles, then save annotations; existing annotation files can also be displayed. The graph preserves the three documented formats and key UI, settings, and localization components. Sampled excerpts show the canvas/shape and format-writer relationships, but not most main-window event wiring, so those links are omitted or marked unverified.
Main entry points: labelImg.py Main Window · labelFile.py Format Facade · canvas.py Drawing Canvas · labelDialog.py Label Dialog
Components 21
Application UI
- Main Window
labelImg.py - Image Workflow
labelImg.py - Preferences
libs/settings.py - Qt Settings Store
libs/settings.py
Annotation Editing
- Drawing Canvas
libs/canvas.py - Rectangle Shapes
libs/shape.py - Label Dialog
libs/labelDialog.py - Default Class Picker
libs/default_label_combobox.py
Annotation Formats
- Format Facade
libs/labelFile.py - PASCAL VOC I/O
libs/pascal_voc_io.py - YOLO I/O
libs/yolo_io.py - CreateML I/O
libs/create_ml_io.py - CreateML Writer
libs/create_ml_io.py
UI Support
- Toolbar
libs/toolBar.py - Color Dialog
libs/colorDialog.py - Zoom Control
libs/zoomWidget.py - Brightness Control
libs/lightWidget.py - Localization
libs/stringBundle.py - Qt Utilities
libs/utils.py - Label Combo Box
libs/combobox.py
Other components
- Annotator
Connections 21
- Annotator → Main Window: launches
README.rst - Annotator → Image Workflow: opens images
README.rst - Annotator → Drawing Canvas: draws boxes
README.rst - Annotator → Format Facade: saves annotations
README.rst - Main Window → Drawing Canvas: uses canvas
labelImg.py - Main Window → Image Workflow: manages images
labelImg.py - Main Window → Preferences: loads preferences
labelImg.py - Main Window → Toolbar: configures actions
labelImg.py - Main Window → Label Dialog: prompts labels
labelImg.py - Main Window → Default Class Picker: selects classes
labelImg.py - Main Window → Color Dialog: sets colors
labelImg.py - Main Window → Zoom Control: controls zoom
labelImg.py - Main Window → Brightness Control: controls brightness
labelImg.py - Main Window → Localization: loads strings
labelImg.py - Drawing Canvas → Rectangle Shapes: draws shapes
libs/canvas.py - Format Facade → PASCAL VOC I/O: delegates VOC
libs/labelFile.py - Format Facade → YOLO I/O: delegates YOLO
libs/labelFile.py - Format Facade → CreateML I/O: delegates CreateML
libs/labelFile.py - Label Dialog → Qt Utilities: validates labels
libs/labelDialog.py - Localization → Qt Utilities: converts text
libs/stringBundle.py - CreateML Writer → CreateML I/O: writes JSON
libs/labelFile.py