Skip to main content

mcPAModelpy - membrane-constrained Protein Allocation Model reconstruction in Python

What is mcPAModelpy?

mcPAModelpy is an extension of the basic framework PAModelpy - powertools to explore the metabolic potential of microorganism. mcPAModelpy possess the basic features of PAModelpy such as:

  • protein-reaction associations
  • infrastructure to include isoenzymes and promiscuous enzymes
  • protein sectors
  • specialized objects to build protein allocation models
  • the possibility to perform a computatinal efficient sensitivity analysis

AND the possibility to include a membrane sector to the model.

The addition of membrane sector would allow the user to constraint the model further by limiting the space where membrane proteins are located, hence more accuracy in the model's prediction.

Installation

PAModelpy is a PiPy package which allows for easy installation with pip:

pip install mcPAModelpy

Note that the package has been tested with the Gurobi selver

Code structure:

  • EnzymeSectors: The objects which are used to store the data of the different enzyme sectors which are added to the genome-scale model
  • PAModel: Proteome Allocation (PA) model class. This class builds on to the cobra.core.Model class from the COBRApy toolbox with functions to build enzyme sectors, to add enzyme kinetics parameters and in the future to perform a sensitivity analysis on the enzyme variables.
  • Enzyme: Different classes which relate enzymes to the model with enzyme constraints and variables.
  • CatalyticEvent: A class which serves as an interface between reactions and enzyme. This allows for easy lookup of Protein-Reaction assocations.
  • PAMValidator: Functions to validate the model predictions with physiology data and giving a graphical overview. The script uses data for E.coli (found in ./Data/Ecoli_physiology) by default.
  • NEW MembraneSector: An object which is used to store the data of the cell membrane and membrane proteins which are added to the genome-scale model.

Enzymatic and sectors data

Enzymatic and sectors data are stored inside an excel data named 'mcPAM_iML1515_EnzymaticData.xlsx'

Tutorial

Import statements

To build a mcPAModel, all import statements from the original PAModel need to be included:

#importing the packages and scripts

import os
from cobra.io import read_sbml_model, load_matlab_model
import sys
import pandas as pd

#load PAMpy modules
from PAModelpy.EnzymeSectors import ActiveEnzymeSector, TransEnzymeSector, UnusedEnzymeSector
from PAModelpy.PAModel import PAModel
from PAModelpy.PAMValidator import PAMValidator
from PAModelpy.configuration import Config

Additionally, an import statements for the MembraneSector needs to be included:

from mcPAModelpy.MembraneSector import MembraneSector

Building a mcPAModel

The first step of building a mcPAModel includes building the original sectors (active, unused, and translational sectors) as described in

https://github.com/iAMB-RWTH-Aachen/PAModelpy/blob/main/Examples/PAModel_example_script.ipynb

In a similar manner as the other sectors, the membrane sector is built as described below:

# building membrane sector 
enzyme_info_path = 'insert the path where "mcPAM_iML1515_EnzymaticData" is stored'
membrane_info = pd.read_excel(enzyme_info_path, sheet_name='Membrane')

area_avail_0 = membrane_info[membrane_info.Parameter == 'area_avail_0'].loc[1,'Value']
area_avail_mu = membrane_info[membrane_info.Parameter == 'area_avail_mu'].loc[2,'Value']
alpha_numbers_dict = active_enzyme_info.set_index(keys='uniprotID').loc[:, 'alpha_numbers'].to_dict()
enzyme_location = active_enzyme_info.set_index(keys='uniprotID').loc[:, 'Location'].to_dict()
cog_class = active_enzyme_info.set_index(keys='uniprotID').loc[:, 'COG_group'].to_dict()

membrane_sector = MembraneSector(area_avail_0=[area_avail_0],
                                 area_avail_mu=[area_avail_mu],
                                 alpha_numbers_dict=alpha_numbers_dict,
                                 enzyme_location=enzyme_location)

After the sectors are built, mcPAM with the genome-scale information and the information about the enzyme and membrane sectors are loaded:

pamodel = PAModel(id_or_model=model,
                   p_tot=0.258,
                   active_sector=active_enzyme_sector,
                   translational_sector=translation_enzyme_sector,
                   unused_sector=unused_protein_sector,
                   membrane_sector=membrane_sector,
                   sensitivity = True,
                   configuration=config
                   )

License

Copyright institute of Applied Microbiology, RWTH Aachen University, Aachen, Germany (2023)

PAModelpy is free of charge open source software, which can be used and modified for your particular purpose under the MIT or Apache 2.0 of the users choice.

Please note that according to these licenses, the software is provided 'as is', WITHOUT WARRANTY OF ANY KIND, without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Metadata

Release files for mcPAMpy 0.0.1

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

Source distribution (sdist)

Source distribution for mcPAMpy 0.0.1
File Size Uploaded Provenance
mcpampy-0.0.1.tar.gz 47.3 kB Without provenance Details

Built distribution (wheel)

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

Total release size: 97.4 kB

Release files / mcpampy-0.0.1.tar.gz

Download URL mcpampy-0.0.1.tar.gz
Size 47.3 kB
Tags Source
SHA-256 checksum
How to use checksums
350c8e76740dbd9e6bb01e28572ca22dd378dd54ddaaaea038c7fcff0bc7bf57
BLAKE2b-256 checksum
How to use checksums
ebc63532987c40e62316643eb288f2b116cb8f2dfa14c3803623a8ea75d423bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.4

Release files / mcPAMpy-0.0.1-py3-none-any.whl

Download URL mcPAMpy-0.0.1-py3-none-any.whl
Size 50.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3cb379a51d1432f899cb9282b7b2e4066b573f860f69f68447d91e4ebcf7e59e
BLAKE2b-256 checksum
How to use checksums
9555a22cc654ad05ebb7defb202746592c348573f527a27af96f6707c1bbacf0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.4

Security for mcPAMpy 0.0.1

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.0.1 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