XE

xtmtd/entomokit

Developer tools

Эта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал

20 stars Качество 64 Тренд 18MIT

A Python Toolkit for Insect Image Dataset Construction and Classification

Обзор

A Python-based toolkit for building insect image datasets. EntomoKit provides a unified entomokit CLI for frame extraction, segmentation, morphology measurement, synthesis, cleaning, augmentation, dataset splitting, AutoMM classification and environment diagnostics, plus an entomokit-workflow skill for AI assistants. The pipeline is composable; only the steps your data needs are required. 1. extract-frames — turn videos into still frames. 2. segment — cut insects out of images and optionally write annotations. 3. measure — optional: morphology metrics from segmentation masks. 4. synthesize — optional: composite RGBA cutouts onto new backgrounds. 5. clean — resize, pad and deduplicate images. 6. augment — optional: expand a small training set. 7. split-csv — build train/val/test CSVs. 8. classify train → classify predict / classify evaluate / classify embed / classify cam / classify export-onnx.

README

Показан фрагмент оригинального README. Открыть оригинал.

Insect Dataset Toolkit (EntomoKit)

中文文档 | English

A Python-based toolkit for building insect image datasets. EntomoKit provides a unified entomokit CLI for frame extraction, segmentation, morphology measurement, synthesis, cleaning, augmentation, dataset splitting, AutoMM classification and environment diagnostics, plus an entomokit-workflow skill for AI assistants.

Workflow Overview

The pipeline is composable; only the steps your data needs are required.

  1. extract-frames — turn videos into still frames.
  2. segment — cut insects out of images and optionally write annotations.
  3. measure — optional: morphology metrics from segmentation masks.
  4. synthesize — optional: composite RGBA cutouts onto new backgrounds.
  5. clean — resize, pad and deduplicate images.
  6. augment — optional: expand a small training set.
  7. split-csv — build train/val/test CSVs.
  8. classify train → classify predict / classify evaluate / classify embed / classify cam / classify export-onnx.

You can start at any step: for example go straight from clean to classify train when the images are already labelled, or use segment alone for mask extraction. AI-assisted runs follow the skill’s own guided policy, not this list.

Requirements and Installation

  • Python 3.9+
  • Linux, macOS or Windows
git clone https://github.com/xtmtd/entomokit.git
cd entomokit

Install into an isolated environment (recommended):

uv venv .venv
source .venv/bin/activate
uv pip install -e .

Equivalent alternatives: python -m venv .venv && source .venv/bin/activate, or conda create -n entomokit python=3.11 -y && conda activate entomokit. Installing directly into a global environment is possible but risks dependency conflicts.

Command extras:

Extra Adds
.[video] extract-frames (OpenCV video decoding)
.[segmentation] SAM3 segmentation, SAM3 repair and synthesis annotation output
.[measurement] measure (morphology metrics, skeleton computation)
.[synthesis] synthesize (polygon simplification, COCO annotations)
.[cleaning] clean perceptual-hash dedup
.[augment] augment (albumentations)
.[classify] classify train/predict/evaluate/embed/cam/export-onnx (AutoMM, timm, GradCAM, UMAP, ONNX)
.[dev] pytest and coverage

measure and synthesize also import scikit-image, which neither the measurement nor the synthesis extra declares; install .[segmentation] (which declares it) or add scikit-image explicitly alongside those extras.

Install several at once, for example the full development set:

uv pip install --only-binary :all: stringzilla
pip install -e ".[dev,classify,segmentation,synthesis,measurement,video,cleaning,augment]"

The stringzilla line above is required before installing .[augment] on platforms where only its binary wheel is available. AutoMM publishes its own install notes at

Открыть полный README на GitHub

Рекомендуемые инструменты

Попробуйте другой запрос или уберите фильтр.

Установка

npx skillfish add xtmtd/entomokit
Новичок в MCP? Начните с руководства на mcpskill.org →