Albeck model tests

[source]

This module contains a number of tests that can be used to verify that the behavior of the MOMP-only sub-models based on [Albeck2008] and re-written in PySB match the original publication. To verify that the PySB version of the models match the original models (which were written in MATLAB), timecourse data was generated in MATLAB using the original MATLAB code, and saved in tab-separated data files (albeck_11{b-f}.tsv). The PySB models are then run using the same input and the output is verified to match the original data (within integration tolerances).

This model verification procedure is written as a series of unit tests, one for each sub-model, using the built-in Python package unittest.

To run the tests, simply execute this file at the command line, i.e.:

python test_albeck_models.py

and all tests should pass.

Functions and Classes

earm.tests.test_albeck_models.add_caspase8(model)[source]

Add the reaction C8 + Bid <-> C8:Bid -> C8 + tBid.

All of the MOMP sub-models in this model repository have been written to have tBid as their upstream “interface,” and Smac/Cytochrome C release as their downstream “interface.” However, in the original publication [Albeck2008], the authors incorporated the additional upstream step of Bid cleavage by caspase 8 into all of the sub-models that they explored.

Therefore, to match the output of the PySB models in this repository to the output produced by the original MATLAB models, it is necessary to add the upstream caspase-8:Bid reactions.

This function takes a model object and adds the necessary elements:

  • Caspase-8 Monomer
  • Caspase-8 initial condition
  • Caspase-8/Bid cleavage reaction and associated parameters

In addition, since in the original publication the plotted figures considered Smac release kinetics in the absence of Cytochrome C release, this function sets the Cytochrome C initial condition to 0 (this prevents Cytochrome C from competing with Smac for pore transport, which affects the observed Smac release kinetics slightly).

earm.tests.test_albeck_models.run_figure_sim(model)[source]

Run the C8 dose-response series shown in Fig. 11 of [Albeck2008].

Returns:

[t, outputs] : list containing two numpy.array objects

t: The time coordinates of each timepoint, in seconds, from 0 to

60,000 seconds (15 hours), at 60-second intervals.

outputs: A 901 x 7 array. Each row corresponds to the fraction of Smac

released into the cytosol at each timepoint. Each column correspond to a distinct caspase 8 dose, from lowest to highest: [1, 5, 10, 50, 100, 500, 1000], in molecules per cell.

earm.tests.test_albeck_models.plot_figure(model, data_file)[source]

Plot the PySB model output alongside the original MATLAB output.

This function is not used explicitly by any of the testing code, but it is useful for a visual comparison of the output of the PySB model to the original MATLAB model output.

Parameters:

model : pysb.model

The PySB MOMP model.

data_file : The original MATLAB data file.

earm.tests.test_albeck_models.matches_figure(model, data_file)[source]

Test whether the PySB model output matches the original MATLAB output.

Calls run_figure_sim() to generate the PySB model output, then loads the MATLAB data file and compares the outputs using the function numpy.allclose. Returns True if every timepoint from the dose-response series matches the original MATLAB output to within one order of magnitude of the integration tolerance.

class earm.tests.test_albeck_models.TestAlbeck11b(methodName='runTest')[source]

Test the PySB model based on the topology shown in Figure 11b.

Methods

test_figure()[source]

Test that the model reproduces the plots shown in Figure 11b.

class earm.tests.test_albeck_models.TestAlbeck11c(methodName='runTest')[source]

Test the PySB model based on the topology shown in Figure 11c.

Methods

test_figure()[source]

Test that the model reproduces the plots shown in Figure 11c.

class earm.tests.test_albeck_models.TestAlbeck11d(methodName='runTest')[source]

Test the PySB model based on the topology shown in Figure 11d.

Methods

test_figure()[source]

Test that the model reproduces the plots shown in Figure 11d.

class earm.tests.test_albeck_models.TestAlbeck11e(methodName='runTest')[source]

Test the PySB model based on the topology shown in Figure 11e.

Methods

test_figure()[source]

Test that the model reproduces the plots shown in Figure 11e.

class earm.tests.test_albeck_models.TestAlbeck11f(methodName='runTest')[source]

Test the PySB model based on the topology shown in Figure 11f.

Methods

test_figure()[source]

Test that the model reproduces the plots shown in Figure 11f.