Giter Site home page Giter Site logo

circe's Introduction

Circe logo


CIRCE: Cis-regulatory interactions between chromatin regions

Unit_Tests codecov PyPI version Downloads

Description

This repo contains a python package for inferring co-accessibility networks from single-cell ATAC-seq data, using skggm for the graphical lasso and scanpy for data processing.

It is based on the pipeline and hypotheses presented in the manuscript "Cicero Predicts cis-Regulatory DNA Interactions from Single-Cell Chromatin Accessibility Data" by Pliner et al. (2018). This R package Cicero is available here.


Metacalls computation might create differences, but scores will be identical applied to the same metacalls (cf comparison plots below). It should run significantly faster than Cicero (e.g.: running time of 5 sec instead of 17 min for the dataset 2).

If you have any suggestion, don't hesitate ! This package is still a work in progress :)

Installation

The package can be installed using pip:

pip install circe-py

and from github

pip install "git+https://github.com/cantinilab/circe.git"

Warning: If you clone the repo, don't stay in the repo to run your script because python will import the non-compiled cython file (probable error: circe.pyquic does not have a quic function)

Minimal example

import anndata as ad
import circe as ci

# Load the data
atac = ad.read_h5ad('atac_data.h5ad')
atac = ci.add_region_infos(atac)

# Compute the co-accessibility network
ci.compute_atac_network(atac)

# Extract the network and find CCANs modules
circe_network = ci.extract_atac_links(atac)
ccans_module = ci.find_ccans(atac)

Visualisation

ci.plot_connections(
    adata,
    chromosome="chr1",
    start=1e7,
    end=1.3e7

Comparison to Cicero R package


On the same metacells obtained from Cicero code.

All tests can be found in the circe benchmark repo

Real dataset 2 - subsample of 10x PBMC (2021)

  • Pearson correlation coefficient: 0.999958
  • Spearman correlation coefficient: 0.999911

Performance on real dataset 2:

  • Runtime: ~100x faster
  • Memory usage: ~5x less

Coming:

  • Calculate metacells !
  • Add stats on similarity on large datasets.
  • Add stats on runtime, memory usage.
  • Implement the multithreading use. Should speed up even more.
  • Fix seed for reproducibility.

Usage

It is currently developped to work with AnnData objects. Check Example1.ipynb for a simple usage example.

Citation

Trimbour Rémi (2024). Circe: Co-accessibility network from ATAC-seq data in python (based on Cicero package). Package version 0.2.0.

circe's People

Contributors

r-trimbour avatar

Stargazers

 avatar Yanchi Su avatar Shahroze Abbas avatar Alastair Smith avatar Edoardo Giacopuzzi avatar Davide Cittaro avatar Jiankun_Zhang avatar Yuzhe Li avatar  avatar  avatar Jérémie Muller-Prokob avatar Geert-Jan Huizing avatar  avatar

Watchers

Daniele Capocefalo avatar  avatar  avatar Shahroze Abbas avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.