ParkerLabel README

The project's README from github.com/Parker-Lyu/ParkerLabel. As one markdown file: README.md.

English | 简体中文 | 繁體中文 | 日本語 | 한국어

ParkerLabel icon

ParkerLabel

Runs entirely on the CPU—no GPU required.

A lightweight, polished AI-assisted interactive annotation tool for object detection and instance segmentation.

Each interactive mask-decoder inference takes approximately 20 ms on Apple M5 Pro and Intel Core i9-14900KF CPUs.

GitHub Releases macOS arm64 build target Windows x64 build target GPL-3.0-only license

ParkerLabel interactive annotation demo

🎬 Project Overview

Watch the ParkerLabel introduction on YouTube   Watch the ParkerLabel introduction on Bilibili

Run

Use a portable release

  1. Download a published application package for your platform from GitHub Releases or Baiduyun (extraction code: md7r). Releases named models-* contain ONNX models, not application packages.

  2. On macOS and Windows, you need to move the entire extracted ParkerLabel folder to a writable location before opening it.

  3. The macOS package is ad-hoc signed but is not notarized by Apple. The first launch may therefore be blocked by macOS. After attempting to open the app once, open System Settings → Privacy & Security, scroll to the security section, and choose Open Anyway.

  4. On Windows, Microsoft Defender SmartScreen may show Windows protected your PC when you first launch the app. Click More info, then Run anyway.

macOS first-launch warning: click Done macOS Privacy and Security: click Open Anyway
Windows SmartScreen: click More info Windows SmartScreen: click Run anyway

These warnings alone do not mean ParkerLabel is malicious. Portable releases are built with GitHub Actions; you can review the build workflow and build instructions.

Run from source

Install a Conda distribution if you do not already have one. Miniforge is recommended, but other Conda distributions also work. Clone the project from GitHub or Gitee:

git clone https://github.com/Parker-Lyu/ParkerLabel.git

Or:

git clone https://gitee.com/Parker-Lyu/ParkerLabel.git

Then create a Python 3.11 environment, install the dependencies, and start ParkerLabel:

cd ParkerLabel
conda create -n parker-label -c conda-forge python=3.11 -y
conda activate parker-label
python -m pip install -r requirements.txt
python main.py

ParkerLabel automatically verifies and downloads missing ONNX models into pretrain/.

Overview

ParkerLabel supports 中文(简体), 中文(繁體), English, 日本語, 한국어, Deutsch, Français, Italiano, and Español. Use Settings → Interface Language to change the interface language and Settings → Tooltips to control contextual hints.

Use Settings → Keyboard Shortcuts to view, change, clear, or restore key bindings. AI, Manual, and Inspect modes use Q, W, and E by default. In AI mode, positive and negative clicks guide MobileSAM to generate a mask for the current target. The image toolbar uses S to toggle AI prompt points in the overlay view and C to toggle quality checks. Saved bindings take effect immediately and persist across launches.

Category configurations

ParkerLabel includes a read-only configuration containing the 80 standard COCO object-detection categories. Users can create an empty category configuration or copy any existing configuration—including the built-in COCO configuration—to create a new version. Saved configurations are immutable; further changes are made by copying a configuration into another version. User-created configurations are stored in the selected configs/categories/ directory.

Each annotation is bound to a category configuration by its UUID and SHA-256 digest. If another configuration is active, ParkerLabel offers to switch to the required one. The annotation opens read-only if that configuration is unavailable, fails integrity checks, or the user declines the switch.

Portable settings, including the startup category selection, are stored in configs/settings.ini. The application log is configs/app.log; it is cleared on each launch and limited to two 1 MB files while the app runs.

Annotation files

Each source image uses three neighboring artifact files:

The per-image JSON uses COCO annotation fields but is not a complete COCO dataset file. A complete COCO dataset export requires top-level images, annotations, and categories arrays in one dataset JSON.

JSON fields

Regenerate ONNX models

Dependencies: Install torch and torchvision using the PyTorch instructions for your platform, then run python -m pip install timm onnx onnxruntime==1.29.0. Verified versions: torch 2.13.0, torchvision 0.28.0, timm 1.0.19, onnx 1.22.0, and onnxruntime 1.29.0.

Checkpoint: Create pretrain/, then download the official MobileSAM mobile_sam.pt to pretrain/mobile_sam.pt. It is the only weight needed for both exports; no separate TinyViT or SAM checkpoint is required.

Export: From the repository root, run:

python -m mobile_sam.export_mobilesam_encoder --checkpoint pretrain/mobile_sam.pt --output pretrain/encoder.onnx
python -m mobile_sam.export_mobilesam_decoder --checkpoint pretrain/mobile_sam.pt --model-type vit_t --output pretrain/decoder.onnx

These commands regenerate the ONNX models for development. At startup, ParkerLabel checks their sizes and SHA-256 hashes against model-bundle.json and replaces mismatched files with the published models. Custom exports require a matching model manifest. mobile_sam.pt and the export dependencies are not needed at runtime. Model files in pretrain/ are excluded from Git.

Licenses

ParkerLabel's original code, including mobile_sam/export_mobilesam_encoder.py, is licensed under GPL-3.0-only.

The third-party code in mobile_sam/ retains its own licenses: MobileSAM and Segment Anything use Apache License 2.0, and the TinyViT code carries a Microsoft MIT notice. See mobile_sam/LICENSE, mobile_sam/TINYVIT_LICENSE, and mobile_sam/THIRD_PARTY.md for the license texts and attribution.

The GUI uses PyQt5 and Qt under their own licenses. Exact final-package notices, corresponding-source instructions, and Qt replacement instructions are maintained in third_party_licenses/. Model source and export provenance are recorded in docs/model-provenance.md, and the release audit procedure is in docs/release-licenses.md.

Acknowledgements

ParkerLabel's AI-assisted segmentation workflow is built on the work of:

We thank the authors and contributors of both projects for making their work publicly available.

ParkerLabel (Parker-Lyu/ParkerLabel)

Searching Database…

这是什么?ParkerLabel 是一个轻量级、AI 辅助的目标检测与实例分割交互标注工具,使用 MobileSAM 根据点击提示生成掩码。
这是桌面应用,还是要引入代码的库?它是一个带 PyQt5 界面的独立桌面 GUI 应用,以便携版发布包的形式分发,不是库。
怎么把它跑起来?可以从 GitHub Releases(或百度网盘)下载适用于你操作系统的便携版应用包,或者克隆仓库、创建 Python 3.11 Conda 环境、安装依赖后从源码启动。
在 macOS 或 Windows 上安装有什么坑吗?macOS 上的软件包是 ad-hoc 签名但未经公证,首次启动会被拦截,需要你在「隐私与安全性」设置中允许;Windows 上 SmartScreen 可能会警告,需要点击「仍要运行」。
它支持哪些操作系统?已发布 macOS 和 Windows 的便携版软件包,也可以在任何有 Conda 的平台(如 Linux)上从源码运行。
我的数据或图片会被发送到别处吗?不会,一切都在本地 CPU 上运行;标注数据以本地 .npy、.json 和 .mask.png 文件的形式存储在每张源图片旁边。
AI 辅助标注实际上是怎么工作的?在 AI 模式下,你在图像上给出正、负点击,MobileSAM 会根据这些提示实时生成实例掩码(在现代 CPU 上每次推理约 20 毫秒)。
标注时可以用哪些类别集合?ParkerLabel 自带只读的 80 个标准 COCO 类别内置配置,你也可以新建类别配置或复制现有配置,每个配置都通过 UUID 和 SHA-256 摘要来追踪。
标注文件以什么格式保存?每张图片都有一个 JSON 文件,包含每个实例的类别、边界框、面积和未压缩的 COCO RLE 分割,另有缓存的图像嵌入(.npy)和彩色掩码预览(.mask.png);该 JSON 使用 COCO 风格的字段,但并不是完整的 COCO 数据集导出。
界面支持哪些语言?ParkerLabel 的界面支持简体中文、繁体中文、英语、日语、韩语、德语、法语、意大利语和西班牙语,可在设置中切换。
Creator
Parker-Lyu
Size
7.3 MB
Stars
109
Age
1mo
Commits · 90 Days