Resume study with new metric
See original GitHub issue(Not sure if the feature has implemented or not) When we have multiple metric that can evaluate the models, e.g., metric A and B. Assume we have trained 100 trials for metric A and saved the prediction of 100 models. If we want another study to optimize metric B, then compare to begin a new study, we can easily compute last 100 trials’ score of metric B as a better prior.
Motivation
Now I am tuning a model that predict financial market, there are lots of metrics to evaluate the models(for example hit ratio, sharpe ratio, average pl…). How the parameters differ from metrics is interesting. Restart the study of new metric with the prior using the trained trials can save a lot of time.
Description
Simplest way is just give an array of metric_B_value = (number, value)
which is tried trials’ score of new metric. Then start a new study base on this array and the study history with metric A.
For example:
study = optuna.create_study(study_name='Study_metric_B', storage='sqlite:///example.db', study_inherit = "Study_metric_A", new_metric =metric_B_value)
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Thank you for creating this issue. Your motivation is interesting. Although the current Optuna doesn’t provide a feature that directly satisfies your requirement, I think that a private method
Study._append_trial()
can be used for such purpose (see the following toy example):What do you think of it?
Since this issue itself seems to have been solved and there is a related issue #821, please let me close it. FYI, we have implemented the multi-objective feature by #1054.