eab2da81c65974e08b8245bbf8a052093f972df3,generator/bng.py,BngGenerator,generate_reaction_rules,#BngGenerator#,38

Before Change


        for r in self.model.rules:
            label = r.name + ":"
            reactants_code = " + ".join([format_monomerpattern(mp) for mp in r.reactants])
            products_code  = " + ".join([format_monomerpattern(mp) for mp in r.products])
            self.__content += ("  %-" + str(max_length) + "s  %s -> %s    %s\n") % (label, reactants_code, products_code, r.rate.name)
        self.__content += "end reaction rules\n\n"

    def generate_observables(self):

After Change


        max_length = max([len(r.name) for r in self.model.rules]) + 1  // +1 for the colon
        for r in self.model.rules:
            label = r.name + ":"
            reactants_code = format_reactionpattern(r.reactant_pattern)
            products_code  = format_reactionpattern(r.product_pattern)
            arrow = "->"
            if r.is_reversible:
                arrow = "<->"
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: pysb/pysb
Commit Name: eab2da81c65974e08b8245bbf8a052093f972df3
Time: 2009-08-09
Author: jmuhlich@bitflood.org
File Name: generator/bng.py
Class Name: BngGenerator
Method Name: generate_reaction_rules


Project Name: pysb/pysb
Commit Name: eab2da81c65974e08b8245bbf8a052093f972df3
Time: 2009-08-09
Author: jmuhlich@bitflood.org
File Name: generator/bng.py
Class Name: BngGenerator
Method Name: generate_observables


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_reactionpattern