Skip to main content

Epigenomic diagnosis of acute leukemia

Project description

ALMA Classifier

Nat Commun Downloads Python versions Docker pulls Research Use Only

Epigenomic diagnosis of acute leukemia and prognosis of AML.

Models

  1. ALMA Subtype: Classifies 27 subtypes of acute leukemia according to WHO 2022 + healthy control
  2. 38CpG AML Signature: Risk stratification using targeted 38 CpG panel
  3. AML Epigenomic Risk (v0.1.4 only): Predicts 5-year mortality probability for AML patients

What's New

  • ALMA Subtype v2
    • Autoencoder–transformer architecture
    • Near-perfect accuracy across methylation arrays and nanopore epigenomes
    • v0.1.4 classifiers (from the publication) remain available in pip and docker.

Installation

Docker (recommended)

docker pull fmarchi/alma-classifier:0.2.1

Python 3.11

pip install --extra-index-url https://download.pytorch.org/whl/cpu "torch==2.8.0+cpu"
pip install alma-classifier

If you have a CUDA-enabled system, want GPU acceleration, and don't mind the extra dependency weight, install the matching CUDA build instead with pip install torch>=2.8.0.

Usage

Docker

Run demo:

docker run --rm -v "$(pwd)":/work -w /work fmarchi/alma-classifier:0.2.1 \
  alma-classifier --demo

Run using your data:

# Transfer your input data to current working directory
docker run --rm -v "$(pwd)":/work -w /work fmarchi/alma-classifier:0.2.1 \
  alma-classifier -i /work/your_data.pkl

Python 3.11 (CLI)

Run demo:

alma-classifier --demo

Run using your data:

alma-classifier -i path/to/your_data.pkl

Input Formats

Illumina Methylation450k or EPIC

Prepare a .pkl (or csv.gz) dataset with the following structure:

  • Rows: Samples
  • Columns: CpG sites
  • Values: Beta values (0-1)

Got .idat files? Use SeSAMe first.

Nanopore whole genome sequencing

Follow the standard bedMethyl format with these key columns:

  • Column 1: chrom - Chromosome name
  • Column 2: start_position - 0-based start position
  • Column 4: modified_base_code - Single letter code for modified base
  • Column 11: fraction_modified - Percentage of methylation (0-100)

Got .bam files? Use modkit first:

modkit pileup \
"$bam_file" \
"$bed_file" \
-t $threads \
--combine-strands \
--cpg \
--ignore h \
--ref ref/hg38.fna \
--no-filtering

CLI options

usage: alma-classifier [-h] [-i INPUT_DATA] [-o OUTPUT] [--download-models] [--demo] [--all_probs]

🩸🧬 ALMA Classifier  Epigenomic diagnosis of acute leukemia (research use only) 🧬🩸

options:
  -h, --help            show this help message and exit
  -i INPUT_DATA, --input_data INPUT_DATA
                        Input file: .pkl with β‑values, .csv/.csv.gz with β‑values, or .bed/.bed.gz nanopore file
  -o OUTPUT, --output OUTPUT
                        .csv output (default: alongside input data)
  --download-models     Download model weights from GitHub release
  --demo                Run demo with example dataset
  --all_probs           Include all subtype/class probabilities as separate columns in the output

Output

Results include subtype classification, risk prediction, and confidence scores.

Important limitations

  • The diagnostic model does not currently recognize: AML with Down Syndrome, juvenile myelomonocytic leukemia, transient abnormal myelopoiesis, low-risk MDS, or lymphomas. We need reference methylation data for these patient populations.
  • Follow preprocessing as instructed in "Input Formats" above. Different or erroneous preprocessing may lead to poor performance. This applies to bad wet-lab handling of samples.
  • The models will attempt to work with missing CpGs. Ideally, use Methylation Array 450k,EPIC or WGS Nanopore Seq with >5x coverage. Anything below that may compromise performance.

Datasets

Our datasets are publicly available for research:

Join us in building alma-classifier v3!

We are developing ALMA-Classifier v3, featuring an enhanced model architecture and a substantially expanded reference dataset that includes new hematologic disease populations.

Our training data, model weights, and code will remain fully open-source and open-access to accelerate research and clinical translation.

If you are interested in contributing data, collaborating on model development, or integrating the classifier into your research or clinical pipeline, please reach out to francisco@almagenomics.com.

Citation

Marchi, F., Shastri, V.M., Marrero, R.J. et al. Epigenomic diagnosis and prognosis of Acute Myeloid Leukemia. Nat Commun 16, 6961 (2025). https://doi.org/10.1038/s41467-025-62005-4

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

alma_classifier-0.2.2.tar.gz (3.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

alma_classifier-0.2.2-py3-none-any.whl (3.9 MB view details)

Uploaded Python 3

File details

Details for the file alma_classifier-0.2.2.tar.gz.

File metadata

  • Download URL: alma_classifier-0.2.2.tar.gz
  • Upload date:
  • Size: 3.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.3

File hashes

Hashes for alma_classifier-0.2.2.tar.gz
Algorithm Hash digest
SHA256 c26ad913401190bbc7b315dd05b0cf658b96edf3e4ea2c6a62bfac8a1cefaf93
MD5 7a642df3b0319b9b07b7cf62bc0002f9
BLAKE2b-256 fb3a0d66dd6eda46bed6d9d87ed9f458edff58956ec9be57950e7a1b61ae60bd

See more details on using hashes here.

File details

Details for the file alma_classifier-0.2.2-py3-none-any.whl.

File metadata

File hashes

Hashes for alma_classifier-0.2.2-py3-none-any.whl
Algorithm Hash digest
SHA256 28dac40cf6b20cf9672402f67df2280536918debd8a3e12399eb1d57331285b8
MD5 d3b017bcd72b3e27a2588c1f7bc907d8
BLAKE2b-256 6887b2963176bccfc6e5d65384025311d919e203de2c96a658665e687efa440b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page