New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
&benheid [BUG] allow alpha
and coverage
to be passed again via metrics to evaluate
#5354
Conversation
The reindexing in line 290 (not changed) is the problem. Since the indexes are named differently. See pandas documentation: https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.reindex.html Thus, This also requires some changes in the test, since accessing columns using As an alternative, we could also try to rename all columns. However, this might lead to problems if multiple PinbalLosses are used in |
I see. So we need to restore the expected column names at least until the deprecation has taken place. For the same reason I asked @hazrulakmal to keep the old column names for now (not breaking anything for the user!), I think we need to keep them here as well. More precisely, my preferred solution would be:
If this happens before the reindex, that should solve the issue? |
Yes. The challenge might be to ensure that we restore it correctly. I.e., we need to have a mapping somewhere from old to new.
yes. Would you then also directly introduce a legacy parameter that enables to control the naming of the columns? |
The fix is based on:
I have not introduced a legacy parameter |
amazing. Very elegant. I would have written sth more painful. |
I approve your part, do but I cannot approve my own code... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now. However, the code is partly written by me. However, I can technically approve it. If you are fine with my changes and I am fine with yours, it should be okay I suppose..
I'm fine with your changes, as said - that implies the four eyes principle is satisfied. |
alpha
and coverage
to be passed again via metrics to evaluate
alpha
and coverage
to be passed again via metrics to evaluate
…in-ForecastX * origin/main: [BUG] ensure `Catch22` parameter setting `n_jobs = -1` uses all cores (sktime#5361) [MNT] simplified CI - merge windows CI step with test matrix (sktime#5362) &benheid [BUG] allow `alpha` and `coverage` to be passed again via metrics to `evaluate` (sktime#5354) [ENH] Link `test_interval_wrappers.py` to changes in `evaluate` for conditional testing (sktime#5337) [ENH] Add a CurveFitForecaster based on scipy optimize_curve (sktime#5240) [ENH] in scitype check, replace base class register logic with type tag inspection (sktime#5288)
* origin/main: [BUG] ensure `Catch22` parameter setting `n_jobs = -1` uses all cores (sktime#5361) [MNT] simplified CI - merge windows CI step with test matrix (sktime#5362) &benheid [BUG] allow `alpha` and `coverage` to be passed again via metrics to `evaluate` (sktime#5354) [ENH] Link `test_interval_wrappers.py` to changes in `evaluate` for conditional testing (sktime#5337)
* origin/split-ci: Revert "added 3.12 in matrix" [BUG] ensure `Catch22` parameter setting `n_jobs = -1` uses all cores (sktime#5361) [MNT] simplified CI - merge windows CI step with test matrix (sktime#5362) &benheid [BUG] allow `alpha` and `coverage` to be passed again via metrics to `evaluate` (sktime#5354) [ENH] Link `test_interval_wrappers.py` to changes in `evaluate` for conditional testing (sktime#5337)
…recasting * origin/split-ci: Revert "added 3.12 in matrix" [BUG] ensure `Catch22` parameter setting `n_jobs = -1` uses all cores (sktime#5361) [MNT] simplified CI - merge windows CI step with test matrix (sktime#5362) &benheid [BUG] allow `alpha` and `coverage` to be passed again via metrics to `evaluate` (sktime#5354) [ENH] Link `test_interval_wrappers.py` to changes in `evaluate` for conditional testing (sktime#5337)
This PR ensures pre-existing syntax to pass
alpha
andcoverage
via metrics toevaluate
works again, fixing #5336.Not commenting here on whether the status quo is a good idea or not (I think it was cleaner to remove it, or is, in the long run), but such a change should not happen without deprecation.
FYI @hazrulakmal.
Question to the reviewers, especially @hazrulakmal: do we need to change the naming convention to something else to ensure we do not change the names - or their order - again, accidentally?
Depends on #5337, so this change should trigger the test that is failing on
main
.