-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Time series ensemble models #1105
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
Conversation
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.
Hi @TremaMiguel , In the notebook, it would be god to show an example of the 3 Ensemble methds that show difference in results. Currently all 3 show the same result.
Also, is this expected? Shouldn't the one with weights give a different result?
) | ||
assert np.all(y_pred.index == expected) | ||
|
||
|
||
@pytest.mark.parametrize("method", _ENSEMBLE_METHODS) | ||
def test_blend_model(load_setup, load_models, method): |
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.
Could you add a unit test for blending of only a subset of models?
ts_blender = exp.blend_models([arima_model, naive_model], optimize='MAPE_ts')
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.
@ngupta23 could you clarify some details about what are we expecting to test by pairs?
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.
I think in the example notebook you have an example with blending only a subset of models. It would be good to check this through a unit test to make sure that it does not always produce the same results as when all models are blended.
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.
sure, @ngupta23 I added a functional test to assert that predictions from mean
, median
and voting
ensemble differ considering all the models available in the ts module.
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.
LGTM, I've got nothing to add that @ngupta23 hasn't said already. Just please be careful with formatting changes unrelated to actual PR.
@ngupta23 sorry, the voting ensemble called the |
Related Issuse or bug
Fixes: [#1094]
Describe the changes you've made
Major changes include:
EnsembleForecaster
withmean
,median
andvoting
methods. linkMinor changes include:
Series
conversion when calling sktime metrics. Pycaret Experiment handles data asDataFrame
internally. linkType of change
Please delete options that are not relevant.
How Has This Been Tested?
The following tests are included
test_blend_models
test parametrically theTimeSeriesExperiment.blend_models()
method. linkwith the addition of the following fixtures to share components through tests:
load_setup
fixture to share an experiment to testTimeSeriesExperiment
different functionalities. linkload_ts_models
fixture to share timeseries models to testTimeSeriesExperiment
different functionalities linkDescribe if there is any unusual behaviour of your code(Write
NA
if there isn't)blend_model
fails with sktimePolyTrend
Model, when retrieving the id of the model container through a dictionary,None
is returned as the key.Checklist: