ecoli.processes.transcript_initiation

Transcript Initiation

This process models the binding of RNA polymerase to each gene. The number of RNA polymerases to activate in each time step is determined such that the average fraction of RNA polymerases that are active throughout the simulation matches measured fractions, which are dependent on the cellular growth rate. This is done by assuming a steady state concentration of active RNA polymerases.

class ecoli.processes.transcript_initiation.TranscriptInitiation(parameters=None)[source]

Bases: PartitionedProcess

Transcript Initiation PartitionedProcess

Defaults:

  • fracActiveRnapDict (dict): Dictionary with keys corresponding to media, values being the fraction of active RNA Polymerase (RNAP) for that media.

  • rnaLengths (numpy.ndarray[int]): lengths of RNAs for each transcription unit (TU), in nucleotides

  • rnaPolymeraseElongationRateDict (dict): Dictionary with keys corresponding to media, values being RNAP’s elongation rate in that media, in nucleotides/s

  • variable_elongation (bool): Whether to add amplified elongation rates for rRNAs. False by default.

  • make_elongation_rates (func): Function for making elongation rates (see make_elongation_rates()). Takes PRNG, basal elongation rate, timestep, and variable_elongation. Returns an array of elongation rates for all genes.

  • active_rnap_footprint_size (int): Maximum physical footprint of RNAP in nucleotides to cap initiation probabilities

  • basal_prob (numpy.ndarray[float]): Baseline probability of synthesis for every TU.

  • delta_prob (dict): Dictionary with four keys, used to create a matrix encoding the effect of transcription factors (TFs) on transcription probabilities:

    {'deltaV' (np.ndarray[float]): deltas associated with the effects of
        TFs on TUs,
    'deltaI' (np.ndarray[int]): index of the affected TU for each delta,
    'deltaJ' (np.ndarray[int]): index of the acting TF for each delta,
    'shape' (tuple): (m, n) = (# of TUs, # of TFs)}
    
  • perturbations (dict): Dictionary of genetic perturbations (optional, can be empty)

  • rna_data (numpy.ndarray): Structured array with an entry for each TU, where entries look like:

    (id, deg_rate, length (nucleotides), counts_AGCU, mw
    (molecular weight), is_mRNA, is_miscRNA, is_rRNA, is_tRNA,
    is_23S_rRNA, is_16S_rRNA, is_5S_rRNA, is_ribosomal_protein,
    is_RNAP, gene_id, Km_endoRNase, replication_coordinate,
    direction)
    
  • idx_rRNA (numpy.ndarray[int]): indexes of TUs corresponding to rRNAs

  • idx_mRNA (numpy.ndarray[int]): indexes of TUs corresponding to mRNAs

  • idx_tRNA (numpy.ndarray[int]): indexes of TUs corresponding to tRNAs

  • idx_rprotein (numpy.ndarray[int]): indexes of TUs corresponding ribosomal proteins

  • idx_rnap (numpy.ndarray[int]): indexes of TU corresponding to RNAP

  • rnaSynthProbFractions (dict): Dictionary where keys are media types, values are sub-dictionaries with keys ‘mRna’, ‘tRna’, ‘rRna’, and values being probabilities of synthesis for each RNA type

  • rnaSynthProbRProtein (dict): Dictionary where keys are media types, values are arrays storing the (fixed) probability of synthesis for each rProtein TU, under that media condition.

  • rnaSynthProbRnaPolymerase (dict): Dictionary where keys are media types, values are arrays storing the (fixed) probability of synthesis for each RNAP TU, under that media condition.

  • replication_coordinate (numpy.ndarray[int]): Array with chromosome coordinates for each TU

  • transcription_direction (numpy.ndarray[bool]): Array of transcription directions for each TU

  • n_avogadro (unum.Unum): Avogadro’s number (constant)

  • cell_density (unum.Unum): Density of cell (constant)

  • ppgpp (str): id of ppGpp

  • inactive_RNAP (str): id of inactive RNAP

  • synth_prob (Callable[[Unum, int], numpy.ndarrray[float]]): Function used in model of ppGpp regulation (see synth_prob_from_ppgpp()). Takes ppGpp concentration (mol/volume) and copy number, returns normalized synthesis probability for each gene

  • copy_number (Callable[[Unum, int], numpy.ndarrray[float]]): see get_average_copy_number(). Takes expected doubling time in minutes and chromosome coordinates of genes, returns average copy number of each gene expected at doubling time

  • ppgpp_regulation (bool): Whether to include model of ppGpp regulation

  • get_rnap_active_fraction_from_ppGpp (Callable[[Unum], float]): Returns elongation rate for a given ppGpp concentration

  • seed (int): random seed to initialize PRNG

_calculateActivationProb(timestep, fracActiveRnap, rnaLengths, rnaPolymeraseElongationRates, synthProb)[source]

Calculate expected RNAP termination rate based on RNAP elongation rate - allTranscriptionTimes: Vector of times required to transcribe each transcript - allTranscriptionTimestepCounts: Vector of numbers of timesteps required to transcribe each transcript - averageTranscriptionTimeStepCounts: Average number of timesteps required to transcribe a transcript, weighted by synthesis probabilities of each transcript - expectedTerminationRate: Average number of terminations in one timestep for one transcript

_rescale_initiation_probs(fixed_indexes, fixed_synth_probs, TU_index)[source]

Rescales the initiation probabilities of each promoter such that the total synthesis probabilities of certain types of RNAs are fixed to a predetermined value. For instance, if there are two copies of promoters for RNA A, whose synthesis probability should be fixed to 0.1, each promoter is given an initiation probability of 0.05.

calculate_request(timestep, states)[source]
defaults: Dict[str, Any]
{   'active_rnap_foorprint_size': 1,
    'active_rnap_footprint_size': 24 [nucleotide],
    'attenuated_rna_indices': array([], dtype=float64),
    'attenuation_adjustments': array([], dtype=float64),
    'basal_prob': array([], dtype=float64),
    'cell_density': 1100.0 [g/L],
    'copy_number': <function TranscriptInitiation.<lambda> at 0x7fc270e54cc0>,
    'delta_prob': {'deltaI': [], 'deltaJ': [], 'deltaV': [], 'shape': ()},
    'emit_unique': False,
    'fracActiveRnapDict': {},
    'get_delta_prob_matrix': None,
    'get_rnap_active_fraction_from_ppGpp': <function TranscriptInitiation.<lambda> at 0x7fc270e54220>,
    'idx_mRNA': array([], dtype=float64),
    'idx_rRNA': array([], dtype=float64),
    'idx_rnap': array([], dtype=float64),
    'idx_rprotein': array([], dtype=float64),
    'idx_tRNA': array([], dtype=float64),
    'inactive_RNAP': 'APORNAP-CPLX[c]',
    'make_elongation_rates': <function TranscriptInitiation.<lambda> at 0x7fc271022660>,
    'n_avogadro': 6.02214076e+23 [1/mol],
    'perturbations': {},
    'ppgpp': 'ppGpp',
    'ppgpp_regulation': False,
    'replication_coordinate': array([], dtype=float64),
    'rnaLengths': array([], dtype=float64),
    'rnaPolymeraseElongationRateDict': {},
    'rnaSynthProbFractions': {},
    'rnaSynthProbRProtein': {},
    'rnaSynthProbRnaPolymerase': {},
    'rna_data': {},
    'seed': 0,
    'synth_prob': <function TranscriptInitiation.<lambda> at 0x7fc270e54c20>,
    'transcription_direction': array([], dtype=float64),
    'trna_attenuation': False,
    'variable_elongation': False}
evolve_state(timestep, states)[source]
name = 'ecoli-transcript-initiation'
ports_schema()[source]
topology
{   'RNAs': ('unique', 'RNA'),
    'active_RNAPs': ('unique', 'active_RNAP'),
    'bulk': ('bulk',),
    'environment': ('environment',),
    'full_chromosomes': ('unique', 'full_chromosome'),
    'listeners': ('listeners',),
    'promoters': ('unique', 'promoter'),
    'timestep': ('timestep',)}
ecoli.processes.transcript_initiation.main()[source]
ecoli.processes.transcript_initiation.run_plot(config, data)[source]