ICB-DCM / pyPESTO

python Parameter EStimation TOolbox
https://pypesto.readthedocs.io
BSD 3-Clause "New" or "Revised" License
207 stars 45 forks source link

Select: problem-specific minimize method for SaCeSS #1339

Open dilpath opened 3 months ago

dilpath commented 3 months ago

Example use

from pypesto.optimize.ess import SacessFidesFactory
from pypesto.select import SacessMinimizeMethod

minimize_options = {
    'startpoint_method': pypesto.startpoint.UniformStartpoints(),
}
minimize_method = SacessMinimizeMethod(
    num_workers=5,
    local_optimizer=SacessFidesFactory(fides_kwargs={
        'verbose': 0,
        'hessian_update': fides.BFGS()
    }),
    max_walltime_s=60,
    sacess_loglevel=logging.DEBUG,
    ess_loglevel=logging.WARNING,
)
model_problem_options = {
    'minimize_method': minimize_method,
    'minimize_options': minimize_options,
    'objective_customizer': objective_customizer,
}

best_models = pypesto_select_problem.select_to_completion(
    candidate_space=candidate_space,
    model_problem_options=model_problem_options,
)
codecov-commenter commented 3 months ago

Codecov Report

Attention: Patch coverage is 0% with 31 lines in your changes are missing coverage. Please review.

Project coverage is 81.20%. Comparing base (3b51af9) to head (1c69991).

Files Patch % Lines
pypesto/select/misc.py 0.00% 27 Missing :warning:
pypesto/select/model_problem.py 0.00% 3 Missing :warning:
pypesto/select/__init__.py 0.00% 1 Missing :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## select_use_old_calibrations #1339 +/- ## =============================================================== - Coverage 84.26% 81.20% -3.06% =============================================================== Files 152 152 Lines 12446 12475 +29 =============================================================== - Hits 10487 10130 -357 - Misses 1959 2345 +386 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

dilpath commented 3 months ago

@Doresic you can use https://github.com/PEtab-dev/petab_select/pull/86 for nicer model hashes, when saving histories