Shape tools and editing
For a guided first exercise, start with Annotate your first image. This page is a reference for the other drawing tools in Labelme 7.6.
Draw and finish a shape
Choose a tool in the left toolbar. After finishing the shape, enter its label in the dialog and confirm it.
Scroll sideways to read the table.
| Tool | Place points | Finish |
|---|---|---|
| Polygon | Click along the outline | Click the first point again, double-click, or press Enter/Space after at least three points |
| Rectangle | Click one corner | Click the opposite corner; hold Shift to make a square |
| Oriented Rectangle | Click a corner, then click to set the first edge's direction | Click a third time to set the edge length and width |
| Circle | Click the center | Click a point on the edge |
| Line | Click the start | Click the end |
| LineStrip | Click successive points | Double-click, Ctrl+click, or press Enter/Space |
| Point | Click the location | The label dialog opens immediately |
Press Escape while drawing to cancel the unfinished shape. Canceling the label dialog normally returns to the unfinished shape. For Point and AI-generated shapes, it discards the draft.
For the AI tools, see AI prompts and models.
Edit existing annotations
Choose Edit Shapes, then click a shape. Drag the shape to move it or drag a point to adjust its boundary. Alt+click a highlighted edge to add a point, using Option on a Mac. Right-click and choose Edit Label to rename it. Choose Delete Shapes to remove the selected shapes immediately. Choose Undo to restore them if needed.
Choosing a drawing tool enters create mode again. Canceling a draft does not itself switch to edit mode.
The keyboard-shortcuts reference lists drawing and navigation shortcuts. Use the toolbar if a shortcut differs on your platform or has been customized.
Read stored coordinates
Each shape stores image coordinates in points. Coordinates use the image's top-left origin, not the screen position or current zoom.
A rectangle stores the two corners in the order they were clicked. Code that requires top-left and bottom-right corners must compute the minimum and maximum x and y values. An oriented rectangle stores four vertices. A circle stores its center and a point on its circumference.
See Read annotations with Python for a runnable example.