opencobra / memote

memote – the genome-scale metabolic model test suite
https://memote.readthedocs.io/
Apache License 2.0
126 stars 26 forks source link

Using json model format #699

Open AgustinPardo opened 4 years ago

AgustinPardo commented 4 years ago

Hi,

Is possible to use a ".json" format model with memote?

I run:

memote report snapshot --filename "report.html"  iEK1011_m7H10_media.json

I get this:

critical: The model could not be loaded due to the following SBML errors.
error: Something went wrong reading the SBML model. Most likely the SBML model is not valid. Please check that your model is valid using the `cobra.io.sbml.validate_sbml_model` function or via the online validator at http://sbml.org/validator .
error:  `(model, errors) = validate_sbml_model(filename)`
error: If the model is valid and cannot be read please open an issue at https://github.com/opencobra/cobrapy/issues .
error: Line 1, Column 0 - #1006: XML content is not well-formed.
error:  - Category: XML content, Severity: 2
Midnighter commented 4 years ago

At the moment this is a feature of the web service only. You can achieve the same effect yourself by loading your model from JSON using cobrapy and then starting memote via the Python API.