5497ef65228a48e6d7f89616f9dc683b34458bb9,pysb/generator/kappa.py,,format_monomerpattern,#Any#,156

Before Change


    // sort sites in the same order given in the original Monomer
    site_conditions = sorted(mp.site_conditions.items(),
                             key=lambda x: mp.monomer.sites.index(x[0]))
    site_pattern_code = ",".join([format_site_condition(site, state)
                                  for (site, state) in site_conditions])
    ret = "%s(%s)" % (mp.monomer.name, site_pattern_code)
    if mp.compartment is not None:
        ret = "%s@%s" % (ret, mp.compartment.name)
    return ret


def format_site_condition(site, state):
    // If the state/bond is unspecified

After Change




def format_monomerpattern(mp):
    return KappaGenerator(None).format_monomerpattern(mp)


def format_site_condition(site, state):
    return KappaGenerator(None).format_site_condition(site, state, "")
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: pysb/pysb
Commit Name: 5497ef65228a48e6d7f89616f9dc683b34458bb9
Time: 2018-05-30
Author: code@alexlubbock.com
File Name: pysb/generator/kappa.py
Class Name:
Method Name: format_monomerpattern


Project Name: pysb/pysb
Commit Name: 5497ef65228a48e6d7f89616f9dc683b34458bb9
Time: 2018-05-30
Author: code@alexlubbock.com
File Name: pysb/generator/kappa.py
Class Name:
Method Name: format_monomer_site


Project Name: pysb/pysb
Commit Name: 5497ef65228a48e6d7f89616f9dc683b34458bb9
Time: 2018-05-30
Author: code@alexlubbock.com
File Name: pysb/generator/kappa.py
Class Name:
Method Name: format_complexpattern