Skip to main content

Binferno: Contrastive Barlow-Twins metagenomic binning

testing badge docs badge

Binferno logo

Binferno is a python-based metagenomic binner that handles metagenomic contigs for both prokaryotic genomes and eukaryotic plastid genomes.

Installation

Binferno is installable via pip. But before installing it, build the conda environment using the conda_env.yaml provided.

mamba env create -n Binferno_env -c conda-forge -c bioconda -c defaults python=3.10
# mamba env create -n Binferno_env -f conda_env.yaml
conda activate Binferno_env

Then, install Binferno via pip:

pip install binferno

Check the installation by running:

binferno --help

Input features

Like most other metagenomic binners, Binferno uses two types of features: sequence composition and coverage. The sequence composition is represented by tetranucleotide frequencies (TNF), while the coverage is represented by the average depth of coverage across the contig.

For improved training, we also offer an option to use the projected kmer features: by multiplying original composition features with the kernel matrix obtained from VAMB.

Corgi encoding is also supported, which is a more compact representation of the sequence composition features with hidden taxonomic information encoded in the latent space.

Because running Binferno requires checkm to evaluate the quality of the bins, please specify the path to the checkm database in the command line when running Binferno.

For prokaryote binning: checkm_data.tar.gz from the official checkm repository can work. For plastid binning, we curated one database with plastid protein HMMs, which can be downloaded from figshare: …

Usage

A simple usage of Binferno is as follows:

binferno --contig-file contigs.fasta --bam-dir path/to/bam/files \
    --output-dir path/to/output/dir --checkm-db path/to/checkm/db \
    --contig-length 1000

Such command will run Binferno with most default parameters: encode contigs by canonical 136-dimension kmer features and coverage mean and standard deviation.

For plastid binning, run with the flag --plastid:

binferno --contig-file contigs.fasta --bam-dir path/to/bam/files \
    --output-dir path/to/output/dir --checkm-db path/to/plastid/checkm/db \
    --contig-length 1000 --plastid

The output bins will be stored in the output directory specified by --output-dir. The final bins will be stored in the subdirectory res_bins.

Besides, other steps, like augmentations, training, and clustering outputs will also be stored as intermediate results in the output directory as augmentations, training and cluster_res subdirectories, respectively.

For more details, please refer to the documentation: https://andyargueasae.github.io/binferno/Binferno.html.

Credits

Binferno is developed by:

Contact:

Metadata

Release files for binferno 0.1.0

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

Source distribution (sdist)

Source distribution for binferno 0.1.0
File Size Uploaded Provenance
binferno-0.1.0.tar.gz 4.3 MB Without provenance Details

Built distribution (wheel)

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

Total release size: 8.8 MB

Release files / binferno-0.1.0.tar.gz

Download URL binferno-0.1.0.tar.gz
Size 4.3 MB
Tags Source
SHA-256 checksum
How to use checksums
b287cffb2dfe0d777e16926ab815cb9ac957112c77fc5bf9bf86b33e14ae560e
BLAKE2b-256 checksum
How to use checksums
cd3b6b2eb96de44ae6a69de08a4c00e0d0bd200dc06a2065beb01930596576db
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.4.1 CPython/3.10.19 Linux/5.14.0-687.48.1.el9_8.x86_64

Release files / binferno-0.1.0-py3-none-any.whl

Download URL binferno-0.1.0-py3-none-any.whl
Size 4.5 MB
Tags Python 3
SHA-256 checksum
How to use checksums
4a89f289253e40bbf7c71c0da1b1b960116940098539f036c7a3f436f85da7c1
BLAKE2b-256 checksum
How to use checksums
c7659b1d182387958b50d55e6d0b4713cf88a290dd42c370c94da2aa9f7b1a54
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.4.1 CPython/3.10.19 Linux/5.14.0-687.48.1.el9_8.x86_64

Security for binferno 0.1.0

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

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