image-annotation-tools

Rectangle and polygon image annotation tools in Python + OpenCV.

https://github.com/mdzahirdu/image-annotation-tools

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (7.4%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

Rectangle and polygon image annotation tools in Python + OpenCV.

Basic Info
  • Host: GitHub
  • Owner: mdzahirdu
  • License: mit
  • Language: Python
  • Default Branch: main
  • Size: 5.86 KB
Statistics
  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created 7 months ago · Last pushed 7 months ago
Metadata Files
Readme License Citation

README.md

🖼️ Image Annotation Tools (Manual Drawing)

This repository provides manual image annotation tools written in Python using OpenCV. These tools allow users to annotate images by drawing rectangular boxes or free-form polygons, and save the annotations in YOLO or LabelMe-compatible formats.


📁 Project Structure

  • draw_rectangle.py
    Annotate using rectangular bounding boxes (saved as .txt in YOLO format)

  • draw_polygon.py
    Annotate using free-form polygons (saved as .json in LabelMe format)


🧰 Requirements

Install required packages:

pip install -r requirements.txt


🖱️ Rectangle Tool Instructions

bash python draw_rectangle.py

  • Left-click + drag = Draw box
  • Press c = Confirm and save
  • Press r = Reset current image
  • Press q = Quit without saving

🧭 Polygon Tool Instructions

bash python draw_polygon.py

  • Click = Add a point
  • Press n = Finish polygon and input label
  • Press s or Enter = Save all shapes
  • Press r = Reset all
  • Press q = Quit

📂 Input/Output

  • Input: images/ folder
  • Output:
    • label/ for YOLO
    • polygon_label/ for polygons

📜 License

MIT License


🙋‍♂️ Author

mdzahirdu

Owner

  • Login: mdzahirdu
  • Kind: user

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it using the metadata below."
title: "Image Annotation Tools"
authors:
  - family-names: "Chowdhury"
    given-names: "Mohammad Zahir Uddin"
    affiliation: "Clarkson Universiy"
    orcid: "https://orcid.org/0009-0009-8194-6669"
date-released: 2025-07-19
version: "1.0.0"
repository-code: "https://github.com/mdzahirdu/image-annotation-tools"

GitHub Events

Total
  • Public event: 1
Last Year
  • Public event: 1

Dependencies

requirements.txt pypi
  • numpy *
  • opencv-python *