Skip to main content

Gene Regulatory Networks Inference using diffusion model

Project description

RegDiffusion logo

Downloads Downloads PyPI - Version

RegDiffusion is a very fast unsupervised regulatory network inference algorithm (just like GENIE3 and GRNBoost2), based on probabilistic diffusion model. It works well on genes and is capable to rapidly (<5min) predict biologically verifiable links from large single cell RNA-seq data with 14,000+ genes.

Zhu H, Slonim D. From Noise to Knowledge: Diffusion Probabilistic Model-Based Neural Inference of Gene Regulatory Networks. J Comput Biol. 2024 Nov;31(11):1087-1103. doi: 10.1089/cmb.2024.0607. Epub 2024 Oct 10. PMID: 39387266; PMCID: PMC11698671.

Installation

RegDiffusion is on pypi.

pip install regdiffusion

Check out the this tutorial for a quick tour of how to use RegDiffusion! If you would like to integrate results from RegDiffusion into the SCENIC pipeline, checkout this tutorial.

Inferred Networks from RegDiffusion

Here are two examples of inferred networks from regdiffusion. The networks are coherent with existing literature and across datasets.

Inference Speed

Inference on networks with 15,000 genes takes under 5 minutes on an A100 GPU. In contrast, previous VAE based models would take more than 4 hours on the same device. Even if you don't have access to those fancy GPU cards, RegDiffusion still works. Inference on the same large network takes roughly 3 hours on a mid-range 12-core CPU.

CLI tool

regdiffusion has a CLI tool now! It takes a count matrix as the input (different from the main API, which needs the data to be log transformed) and returns a table of inferred edges.

usage: regdiffusion [-h] [--output OUTPUT] [--top_gene_percentile TOP_GENE_PERCENTILE] [--k K] [--workers WORKERS] input

Infer a gene regulatory network (GRN) from a single-cell count dataset.

positional arguments:
  input                 Input single-cell count dataset file (CSV or H5AD format).

options:
  -h, --help            show this help message and exit
  --output OUTPUT       Output file path for the edgelist (CSV). Default: rd_grn.csv
  --top_gene_percentile TOP_GENE_PERCENTILE
                        Percentile cutoff to filter weak edges (e.g., 50 for the top 50%). Default: 50
  --k K                 Number of edges per gene to extract (-1 for all edges). Default: -1
  --workers WORKERS     Number of workers to use for edgelist extraction. Default: 4

Citation

If you find our package useful, consider cite our paper! =)

@article{zhu2024noise,
  title={From Noise to Knowledge: Diffusion Probabilistic Model-Based Neural Inference of Gene Regulatory Networks},
  author={Zhu, Hao and Slonim, Donna},
  journal={Journal of Computational Biology},
  volume={31},
  number={11},
  pages={1087--1103},
  year={2024},
  publisher={Mary Ann Liebert, Inc., publishers 140 Huguenot Street, 3rd Floor New~…}
}

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

regdiffusion-0.2.0.tar.gz (13.1 MB view details)

Uploaded Source

Built Distribution

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

regdiffusion-0.2.0-py2.py3-none-any.whl (38.9 kB view details)

Uploaded Python 2Python 3

File details

Details for the file regdiffusion-0.2.0.tar.gz.

File metadata

  • Download URL: regdiffusion-0.2.0.tar.gz
  • Upload date:
  • Size: 13.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.32.3

File hashes

Hashes for regdiffusion-0.2.0.tar.gz
Algorithm Hash digest
SHA256 c8f1c4f4889adbb2f5cb88b6932f3ff32904c573c0a533f41e39771c529ae532
MD5 72cd945712aaa521daec65e0b4e9fd6f
BLAKE2b-256 d55892f3cbbdb292d56ab4dd611ea64cb3973da5c48e4d5af66d799933741a4f

See more details on using hashes here.

File details

Details for the file regdiffusion-0.2.0-py2.py3-none-any.whl.

File metadata

  • Download URL: regdiffusion-0.2.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 38.9 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.32.3

File hashes

Hashes for regdiffusion-0.2.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 f7eedcee9421a621b8a211fda34cf7f306a5e23cd546bbc9a985304db3cd5364
MD5 f114ab568e86796abbd3a470889317da
BLAKE2b-256 5ce6da0054beb4fb6d53e24ba3aa874be258c56d6913e78ce8e49f28794aea29

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