Skip to main content
Loss of provenance

A previous release had provenance metadata, but this release does not. View details.

AlchemyDetect

A desktop GUI application for training and running inference with Detectron2 models.

AlchemyDetect

Features

  • Train object detection and instance segmentation models with a visual interface
  • Live monitoring — real-time loss plot and training logs
  • Inference on single images or entire folders with result visualization
  • Model management — save and load trained weights for later use
  • Export trained models to ONNX or TensorRT for faster deployment
  • Deploy — run exported ONNX/TensorRT models in-app, independent of Detectron2

Supported Models

Model Task
Faster R-CNN (R50-FPN, R101-FPN) Object Detection
RetinaNet (R50-FPN, R101-FPN) Object Detection
Mask R-CNN (R50-FPN, R101-FPN) Instance Segmentation

Quick Start

# Install dependencies (see INSTALL.md for detailed setup)
pip install -r requirements.txt

# Run the application
python main.py

Dataset Format

AlchemyDetect uses COCO JSON format for training datasets. You need:

  • A directory containing your training images
  • A COCO-format JSON annotation file

Usage

Training

  1. Open the Train tab
  2. Select your training images directory and COCO JSON annotation file
  3. Choose a model architecture from the dropdown
  4. Set hyperparameters (learning rate, iterations, batch size)
  5. Choose an output directory
  6. Click Start Training
  7. Monitor progress via the log viewer and loss plot

Inference

  1. Open the Inference tab
  2. Click Load Model and select a trained .pth file (config.yaml will be auto-detected if in the same directory)
  3. Adjust the confidence threshold
  4. Click Run on Image or Run on Folder
  5. Browse results using the navigation buttons

Export (ONNX)

  1. Install the export extra: pip install alchemydetect[export]
  2. Open the Export tab
  3. Click Load Model... and select a trained .pth file (config.yaml is auto-detected)
  4. Choose ONNX, set the opset / input size / fp16 / dynamic-axes options
  5. Pick an output directory and click Export
  6. The output directory will contain model.onnx, the copied config.yaml / class_names.json, and an export_metadata.json describing the model

Detection models (Faster R-CNN, RetinaNet) export reliably. Mask R-CNN (instance segmentation) export is experimental.

ONNX export requires the onnx package — if you skip the [export] extra the Export tab will tell you to install it. TensorRT export appears as a format option only when the tensorrt package is installed (build the ONNX first, then a model.engine); install TensorRT manually to match your CUDA/cuDNN.

Deploy (run exported models)

  1. Open the Deploy tab
  2. Click Load Model... and select an exported model.onnx or model.engine (its export_metadata.json must sit alongside it — produced by the Export tab)
  3. Adjust the confidence threshold
  4. Click Run on Image or Run on Folder and browse results

ONNX runs via onnxruntime (GPU provider used automatically when available); .engine files run via a TensorRT runtime (requires tensorrt + pycuda). Both are independent of Detectron2's predictor. The side panel shows the active runtime provider and the per-image detection time so you can confirm whether inference is on CPU or GPU.

If exported ONNX/TensorRT inference seems slow, check the provider label — if it says CPUExecutionProvider, onnxruntime fell back to CPU (it needs a CUDA runtime matching your onnxruntime-gpu build). The real speedups come from GPU

  • TensorRT.

For how the TensorRT path works and exact install steps (Linux/Windows/Docker), see docs/TensorRT.md.

Logs

The app writes a timestamped session log to a logs/ directory (set ALCHEMYDETECT_LOG_DIR to change the location). Training/export output and inference errors — including worker tracebacks — are mirrored there so you can analyze issues after the fact. The active log path is shown in the status bar.

Tech Stack

  • Python 3.10 or 3.11
  • PyQt6 — Desktop GUI
  • Detectron2 — Object detection / instance segmentation
  • PyTorch — Deep learning backend
  • pyqtgraph — Real-time loss plotting

Security

Loading a model .pth ultimately calls torch.load, which unpickles the file and can execute arbitrary code. Only load model weights you trained or otherwise trust — treat .pth files like executables. Exported .onnx/.engine files and COCO/config files are loaded with safe parsers.

License

MIT

Metadata

Release files for alchemydetect 0.5.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Loss of provenance

These files do not have provenance metadata, despite files in a prior release including this data.

We recommend further investigation before installing these files. View details.

Source distribution (sdist)

Source distribution for alchemydetect 0.5.1
File Size Uploaded Provenance
alchemydetect-0.5.1.tar.gz 49.0 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for alchemydetect 0.5.1
File Interpreter ABI Platform
alchemydetect-0.5.1-py3-none-any.whl Python 3 none any Details

Total release size: 100.0 kB

Release files / alchemydetect-0.5.1.tar.gz

Loss of provenance

This file belongs to a release without provenance metadata, despite a prior release including this data.

We recommend further investigation before installing this file. View details.

Download URL alchemydetect-0.5.1.tar.gz
Size 49.0 kB
Tags Source
SHA-256 checksum
How to use checksums
4180aee754219aeb734baee9c578dc801646b25d2e0ae265d8cd771085e2a24f
BLAKE2b-256 checksum
How to use checksums
ca05ab6e2bc8311ec75c0bdc6e14f0363d64ef2080a43583e5401087e4028d5a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Release files / alchemydetect-0.5.1-py3-none-any.whl

Loss of provenance

This file belongs to a release without provenance metadata, despite a prior release including this data.

We recommend further investigation before installing this file. View details.

Download URL alchemydetect-0.5.1-py3-none-any.whl
Size 51.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
07660b41ed84b0de17f3fb27333c29116ba80302776f0112f63edbd563a308a1
BLAKE2b-256 checksum
How to use checksums
f94768dd05f12f6c0c862079ba78f3323fb2b2b7dcd9ef3a1d5d1da74d8044b0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Security for alchemydetect 0.5.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Loss of provenance

A previous release of these files had provenance metadata, but this release does not.

While this could reflect a routine change by the project maintainers, it may also indicate that the release files have been compromised.

Release comparison

  • Removed 0.5.0 2 files With provenance
  • Added 0.5.1 2 files Without provenance

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page