def _initializeRoadrunner(self): """ Initializes the object and does error checking. Return ------ Roadrunner """ try: rr = te.loads(self.sbmlPath) except Exception as err: msg = "sbmlPath is not a valid file path or URL: %s" \ % self.sbmlPath self.logger.error("_initializeRoadrunner", err) raise ValueError(msg) return te.loads(self.sbmlPath)
def modelHeaders(top_model): """ :param top_model: :type top_model: :return: :rtype: """ r = te.loads(top_model) print(r.selections) r.selections = [ 'time' ] + sorted(["[{}]".format(sid) for sid in r.getFloatingSpeciesIds()] + ["[{}]".format(sid) for sid in r.getBoundarySpeciesIds()]) + sorted( r.getReactionIds()) + sorted(r.getGlobalParameterIds()) print(r.selections)
def output_varaibles(self): return te.loads(self.get_sbml()).getFloatingSpeciesIds()
def test_loads_str(self): r = te.loads(self.sbml_str) self.assertIsNotNone(r)
def test_loads_file(self): r = te.loads(self.sbml_file) self.assertIsNotNone(r)