paulflang / SBML2Julia

A tool to for optimizing parameters of ordinary differential equation (ODE) models. SBML2Julia translates a model from SBML/PEtab format into Julia for Mathematical Programming (JuMP), performs the optimization task and returns the results.
https://sbml2julia.readthedocs.io/en/latest/
MIT License
5 stars 1 forks source link

Solver options #3

Closed sshin23 closed 3 years ago

sshin23 commented 4 years ago

Hi Paul,

Specifying solver options is implemented. You should be able to do, for example:

problem = DisFit.DisFitProblem('tests/fixtures/G2M_copasi.xml', 'tests/fixtures/G2M_copasi.csv',optimizer_options={"linear_solver":"ma57","max_iter":300,"tol":1e-6,"print_level":0})

paulflang commented 4 years ago

Awesome. Thank you very much! I'll update the unit tests and merge.

paulflang commented 4 years ago

@sshin23 I just committed a few unit tests updates to the solver_options branch. When your changes are implemented, the optimization runs without throwing an error. Unfortunately, it does not return a meaningful result (i.e. all species are zero over time). This is why the unit tests in DisFit/tests/test_core.py lines 162 and 168 are failing. I currently commented them out. Could you look into this?

FYI, for running the unit tests I usually go into the DisFit main directory and run python3 -m pytest -p no:warnings -v './tests/test_core.py'.

paulflang commented 4 years ago

When I specify ma57 as solver, I get the following error. @sshin23 : do you know how I can solve that? And if the installation of this solver requires a license that we cannot put into our Docker image, is there another solver we can use for running unit tests in our Docker environment on circleCI.

Exception of type: OPTION_INVALID in file "../../../../Ipopt/src/Algorithm/IpAlgBuilder.cpp" at line 295:
 Exception message: Selected linear solver MA57 not available.
Tried to obtain MA57 from shared library "libhsl.so", but the following error occured:
libhsl.so: cannot open shared object file: No such file or directory