Skip to main content

A Python package for calculating Genetic Minimal Intervention Sets (gMIS) in metabolic networks with regulatory cycles

Project description

cyclic-gMISpy

A Python package for calculating Genetic Minimal Intervention Sets (gMIS) and Minimal Cut Sets (MCS) in metabolic networks with regulatory cycles.

Overview

cyclic-gMISpy is a computational tool designed for identifying minimal genetic interventions in metabolic networks that consider regulatory cycles and gene-protein-reaction (GPR) rules. The package extends traditional minimal cut set analysis by incorporating regulatory network dynamics and cyclic dependencies.

Features

  • Minimal Cut Set (MCS) Calculation: Find minimal sets of reactions that disrupt metabolic objectives
  • Genetic Minimal Intervention Sets (gMIS): Identify minimal gene knockouts considering GPR rules
  • Regulatory Cycles Support: Handle cyclic dependencies in gene regulatory networks
  • Parallel Computing: Multi-threaded calculations for improved performance
  • Multiple Solvers: Support for Gurobi and CPLEX optimization solvers

Installation

Prerequisites

  • Python ≥ 3.7
  • COBRApy
  • NumPy
  • SciPy
  • pandas
  • tqdm
  • bidict
  • bonesis
  • mpbn

Required Optimization Solvers

At least one of the following optimization solvers:

  • Gurobi (recommended for performance)
  • CPLEX

Install Package

# Clone the repository
git clone https://github.com/your-username/cyclic-gMISpy.git
cd cyclic-gMISpy

# Install dependencies
pip install -r requirements.txt

# Install the package
pip install -e .

Or use pip install via piptest

pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ cyclic-gmispy

Quick Start

Basic MCS Calculation

import cobra
from cyclic_gmis import calculateMCS

# Load your metabolic model
model = cobra.io.read_sbml_model("your_model.xml")

gMIS with Regulatory Cycles

import pandas as pd
from cyclic_gmis import calculateGMIS

# Load metabolic model
model = cobra.io.read_sbml_model("your_model.xml")

# Load regulatory network data
regulatory_df = pd.read_csv("regulatory_network.csv")

from cyclic_gmis import calculateParallelGMIS

# Run parallel gMIS calculation
parallel_results = calculateParallelGMIS(
    cobraModel=model,
    regulatory_dataframe=regulatory_df,
    numWorkers=8,
    maxKOLength=3
)

Core Components

Main Functions

  • calculateParallelGMIS(): Calculate genetic minimal intervention sets with regulatory cycles
  • calculateReadjustmentParallel(): Calculate readjustment cycles efficiently

Utilities

  • buildGMatrix(): Build gene-protein-reaction matrix
  • checkGMCS(): Validate computed genetic minimal cut sets
  • saveSolutions(): Save results in various formats
  • setSolver(): Configure optimization solver settings

Problem Definitions

  • Support for different optimization problem formulations
  • Flexible constraint handling
  • Multiple objective functions

Configuration Options

Input Data Formats

Metabolic Models

  • SBML format (via COBRApy)
  • JSON format
  • MAT files

Regulatory Networks

  • CSV files with regulator-target relationships
  • Tab-separated files
  • Custom pandas DataFrame format

Citing

If you use cyclic-gMISpy in your research, please cite:

[Pending]

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Support

For questions and support:

Acknowledgments

  • COBRApy community for metabolic modeling tools
  • Bonesis framework for regulatory network analysis
  • Optimization solver providers (Gurobi, CPLEX, SCIP)

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

cyclic_gmispy-0.3.3.tar.gz (49.7 kB view details)

Uploaded Source

Built Distribution

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

cyclic_gmispy-0.3.3-py3-none-any.whl (109.5 kB view details)

Uploaded Python 3

File details

Details for the file cyclic_gmispy-0.3.3.tar.gz.

File metadata

  • Download URL: cyclic_gmispy-0.3.3.tar.gz
  • Upload date:
  • Size: 49.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.5.10

File hashes

Hashes for cyclic_gmispy-0.3.3.tar.gz
Algorithm Hash digest
SHA256 9a414f3f3eda7ff19d5482ea45e5b3c56e72d82df2dd23306bf7a8a57677fe74
MD5 afad9549168a8586e1a316461bd704cb
BLAKE2b-256 094324ba611b5f3d21dfee3d35dfb9431742e52011ca0a54cfa510e463647c5d

See more details on using hashes here.

File details

Details for the file cyclic_gmispy-0.3.3-py3-none-any.whl.

File metadata

File hashes

Hashes for cyclic_gmispy-0.3.3-py3-none-any.whl
Algorithm Hash digest
SHA256 7b340731322cc9bac7ab0469559262e0f2fc2483068815f27258538070a9ae27
MD5 1a23aaea60f1b1ca674de40ddb4f3fe0
BLAKE2b-256 c95b2b05cc69ed5008ee0df310b7e7a4c676b73bd59c759bf9648bd8b8a0d6f3

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