ModelPolisher
ModelPolisher copied to clipboard
MP introduces (or: reveals) cobrapy validation errors on kinetic laws
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
cielement in this context must refer to a model component; Outside of afunctionDefinition, if acielement is not the first element within a MathMLapply, then theci's value can only be chosen from the set of identifiers of (in L2V1)species,compartment, orparameterobjects; (in L2V2-L2V5),species,compartment,parameterorreactionobjects; (in L3V1)species,compartment,parameter,reactionorspeciesReferenceobjects and (in L3V2)species,compartment,parameter,reaction,speciesReferenceobjects or L3 package objects with defined mathematical meaning. Reference: L3V1 Section 3.4.3 The formula 'FLUX_VALUE' in the math element of thekineticLawuses '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
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>