RustScenic logo

RustScenic

Ekin Kahraman · Mohamed El Moussaoui · Kuan-Lin Huang · Longtao Huangfu · Fuaad Siyaad
Contributions

Fast gene regulatory network analysis for single-cell data.

Infer candidate regulatory relationships and score their activity from RNA and chromatin-accessibility data. Built in Rust, available through Python, and runs on CPUs.

Built and scaled with the Huang Lab at the Icahn School of Medicine at Mount Sinai.

Get started

Current release v0.7.0; regular CPython 3.10–3.14; Linux, macOS and Windows.

python -m pip install rustscenic
python -c "import rustscenic; print(rustscenic.__version__)"

Expected version: 0.7.0.

Run the PBMC3k example · Analyse your own data · Explore a saved network · Installation options

Core analysis runs without Java, Dask, CUDA or Snakemake. The package supports network inference, motif enrichment, activity scoring and multiome analysis.

Performance and validation

Evidence Measured result and scope
RNA+ATAC atlas workflow vs SCENIC+ 14.4× faster with 57% lower measured peak memory on 817,740 real paired cells; median workflow time 102.5 vs 1,474.2 minutes.
RNA atlas workflow vs pySCENIC 4× faster with 96.6% lower measured peak memory on 1.3 million real cells; median workflow time 42.3 vs 168.4 minutes.
RNA scale 1,306,127 real mouse-brain cells in 31m20s median, with 2.97 GB peak analysis PSS on 16 CPU cores; 2,095 selected genes and 256 TFs; three matched seeds.
Matched arboreto comparison 3.06× faster with 78.7% lower peak measured memory than sparse Dask arboreto on the full 1.3 million-cell input, using ratios of medians across three matched seeds.
Memory scaling 21.4% lower topic-model peak memory, with unchanged outputs across three baseline and three optimised runs. Five sampling sweeps test storage, not model convergence.
Selected SCENIC+ stages 11x to 52x faster on sampled real-data inputs of 1,500–2,000 cells. Enhancer methods differ; output agreement is incomplete.
Huang Lab collaborator run 16/17 expected brain transcription factors recovered on 8,215 post-QC cells with v0.4.6. A biological sanity check, not an accuracy estimate.

The atlas workflows use v0.5.0, selected feature panels, three seeds and 16 CPUs. Timings include prepared-input loading through export; raw-data preparation is excluded. Algorithms and outputs differ. Full conditions and biological results.

The earlier million-cell arboreto comparison used RustScenic v0.5.0 and measures core GRN analysis on prepared RNA, excluding preparation and input loading. The approximately 80% memory reduction is specific to the sparse Dask comparator; the sparse multiprocessing comparator gives 2.94× faster analysis and 54.5% lower PSS. Network rankings differ. Measurements and conditions.

The earlier scaling and 20,000-cell experiments remain available. Their v0.5.0 candidate million-cell run took 46m42s, with separate preparation taking 7m18s and peaking at 71.49 GB. The earlier arboreto timings were single observations per node. Neither study establishes a complete million-cell spatial workflow.

Commands, hardware and output agreement · Biological checks and limitations · Collaborator reports

Selected output-agreement results
Check Result
Human brain GEM-X 2k, including preparation RustScenic 11.89 s; SCENIC+ 150.36 s.
GEM-X region-to-gene edge Jaccard 1.000 under the fixed search space; scores are not identical.
GEM-X region AUCell mean Pearson 0.823.
cisTarget AUC kernel vs ctxcore.recovery.aucs Pearson 1.0000.
Remaining GEM-X differences Gene AUCell Pearson 0.386; eRegulon edge Jaccard 0.161.

Full validation record · Release and validation graphic

Explore a network

Open the endothelial-cell example to choose a regulator and inspect its predicted targets. It uses saved results and needs no installation or new model fitting.

ETS1 predicted targets in the endothelial-cell example

The example contains 184,000 retained edges, 85 motif-supported regulons, activity summaries and source-study citations. Download it for offline use.

The full collection covers 704 human Cell Ontology labels from CELLxGENE Census 2025-11-08, with 137.8 million retained edges and 51,527 motif-supported regulons. Download the published dataset or find a cell label and load its results.

Derived data are available under CC BY 4.0, independently hosted on Zenodo. Results are exploratory predictions across pooled tissues and disease annotations; biological accuracy has not been established.

Analysis stages

Stage Python API Purpose
Gene networks rustscenic.grn.infer GRNBoost2-style TF-to-gene inference
AUCell rustscenic.aucell.score Per-cell gene-set activity
cisTarget rustscenic.cistarget.enrich Motif enrichment and support filtering
Topics rustscenic.topics.fit, fit_gibbs scATAC topic modelling
ATAC preprocessing rustscenic.preproc Fragment matrix building and QC
Enhancer links rustscenic.enhancer.link_peaks_to_genes Peak-to-gene linking
eRegulons rustscenic.eregulon.build_eregulons Enhancer-linked regulon assembly
Pipeline rustscenic.pipeline.run Staged RNA and multiome workflows

Documentation and citation

API guide · HPC operation · Scope · Release notes

The package has automated Rust/Python tests, installation checks and real-data validation workflows. Cite the exact RustScenic release used. For the example or full CELLxGENE-derived collection, also cite the dataset, CELLxGENE and contributing studies. Software and example code are Apache-2.0; derived data and resource documentation are CC BY 4.0.