Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/tommyngx/MammoMix/llms.txt

Use this file to discover all available pages before exploring further.

MammoMix is an open-source deep learning framework for breast cancer object detection in mammography images. It provides training pipelines for YOLOS and Deformable DETR models across three benchmark datasets — CSAW, DMID, and DDSM — along with an ensemble inference system (MoCaE) that combines multiple expert models using calibrated confidence scores, Soft-NMS, and Score Voting.

Quickstart

Train your first breast cancer detection model in minutes with a step-by-step guide.

Installation

Install MammoMix and its dependencies from the repository.

Architecture Overview

Understand the model architectures, data flow, and design decisions behind MammoMix.

API Reference

Explore the full Python API for datasets, evaluation, and ensemble inference.

What MammoMix offers

YOLOS Training

Train YOLOS-based detectors on CSAW, DMID, or DDSM with a single command.

Deformable DETR

Train Deformable DETR for improved detection of small lesions in mammograms.

MoCaE Ensemble

Combine multiple expert models with calibrated confidence for improved accuracy.

Evaluation Metrics

Evaluate models with mAP, mAP@50, mAP@75, and other detection metrics.

Data Pipeline

Prepare, split, and merge mammography datasets from raw annotations.

Configuration

Control all training hyperparameters through YAML config files.

Supported datasets

MammoMix supports three mammography benchmark datasets out of the box:
DatasetDescription
CSAWKarolinska Mammography dataset for breast cancer screening
DMIDDigital Mammography Image Database
DDSMDigital Database for Screening Mammography
MammoMix uses Pascal VOC XML annotation format. See Annotation Format for details on how annotations are structured and processed.

Getting started

1

Install dependencies

Clone the repository and install requirements with pip install -r requirements.txt.
2

Prepare your dataset

Run splitting.py to create train/val/test splits from raw mammography data.
3

Configure your experiment

Copy and edit a YAML config from configs/ to set your model, dataset, and hyperparameters.
4

Train and evaluate

Run train.py for YOLOS or train_detrd.py for Deformable DETR. Results are logged to W&B.

Build docs developers (and LLMs) love