Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MP introduces (or: reveals) cobrapy validation errors on kinetic laws #133

Open
Schmoho opened this issue Dec 1, 2024 · 0 comments
Open
Labels
2.1 Issue in the 2.1 branch bug

Comments

@Schmoho
Copy link
Collaborator

Schmoho commented Dec 1, 2024

The issue can be observed on this model: https://www.ebi.ac.uk/biomodels/MODEL1604280030

After application of the polisher the cobrapy validator gives this SBML_ERROR:

"E0 (Error): MathML consistency (core, L40425); A ci element in this context must refer to a model component; Outside of a functionDefinition, if a ci element is not the first element within a MathML apply, then the ci's value can only be chosen from the set of identifiers of (in L2V1) species, compartment, or parameter objects; (in L2V2-L2V5), species, compartment, parameter or reaction objects; (in L3V1) species, compartment, parameter, reaction or speciesReference objects and (in L3V2) species, compartment, parameter, reaction, speciesReference objects or L3 package objects with defined mathematical meaning.
Reference: L3V1 Section 3.4.3
The formula 'FLUX_VALUE' in the math element of the kineticLaw uses 'FLUX_VALUE' that is not the id of a species/compartment/parameter/reaction/speciesReference."

In the following are the unpolished and polished versions. As far as I can tell, the only difference is that the whitespace on the element in the kinetic law has been removed by the polisher (most likely by JSBML, since I don't think we actually touch kinetic laws at all).

The question is whether we should consider this a bug (@draeger):

This is the unpolished original version:

<reaction metaid="meta_r498-AORYZAE-R09748" sboTerm="SBO:0000176" id="r498AORYZAER09748" reversible="true" fast="false" compartment="cytosol">
    <annotation>
     [...]
    </annotation>
    <listOfReactants>
      <speciesReference species="C00004" stoichiometry="1" constant="true"/>
      <speciesReference species="C00016" stoichiometry="1" constant="true"/>
    </listOfReactants>
    <listOfProducts>
      <speciesReference species="C01352" stoichiometry="1" constant="true"/>
      <speciesReference species="C00003" stoichiometry="1" constant="true"/>
    </listOfProducts>
    <kineticLaw>
      <math xmlns="http://www.w3.org/1998/Math/MathML">
        <ci> FLUX_VALUE </ci>
      </math>
      <listOfLocalParameters>
        <localParameter id="LOWER_BOUND" value="0"/>
        <localParameter id="UPPER_BOUND" value="0"/>
        <localParameter id="OBJECTIVE_COEFFICIENT" value="0"/>
      </listOfLocalParameters>
    </kineticLaw>
  </reaction>

this is the polished version:

<reaction compartment="cytosol" fast="false" id="r498AORYZAER09748" metaid="meta_r498-AORYZAE-R09748" reversible="true" sboTerm="SBO:0000176">
        <annotation>
          [...]
        </annotation>
        <listOfReactants>
          <speciesReference constant="true" sboTerm="SBO:0000010" species="C00004" stoichiometry="1" />
          <speciesReference constant="true" sboTerm="SBO:0000010" species="C00016" stoichiometry="1" />
        </listOfReactants>
        <listOfProducts>
          <speciesReference constant="true" sboTerm="SBO:0000011" species="C01352" stoichiometry="1" />
          <speciesReference constant="true" sboTerm="SBO:0000011" species="C00003" stoichiometry="1" />
        </listOfProducts>
        <kineticLaw>
          <math xmlns="http://www.w3.org/1998/Math/MathML">
            <ci>FLUX_VALUE</ci>
          </math>
          <listOfLocalParameters>
            <localParameter id="LOWER_BOUND" value="0" />
            <localParameter id="UPPER_BOUND" value="0" />
            <localParameter id="OBJECTIVE_COEFFICIENT" value="0" />
          </listOfLocalParameters>
        </kineticLaw>
      </reaction>
@Schmoho Schmoho added bug 2.1 Issue in the 2.1 branch labels Dec 1, 2024
@Schmoho Schmoho changed the title Application of the Polisher leads to cobrapy validation errors on kinetic laws MP introduces to cobrapy validation errors on kinetic laws Dec 1, 2024
@Schmoho Schmoho changed the title MP introduces to cobrapy validation errors on kinetic laws MP introduces cobrapy validation errors on kinetic laws Dec 1, 2024
@Schmoho Schmoho changed the title MP introduces cobrapy validation errors on kinetic laws MP introduces (or: reveals) cobrapy validation errors on kinetic laws Dec 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.1 Issue in the 2.1 branch bug
Projects
None yet
Development

No branches or pull requests

1 participant