robjhyndman / forecast

Forecasting Functions for Time Series and Linear Models
http://pkg.robjhyndman.com/forecast
1.12k stars 342 forks source link

Feature Request: Bayesian Optimization #788

Closed rohan-gt closed 5 years ago

rohan-gt commented 5 years ago

Can the hyper-parameter selection of the time series models be implemented using Bayesian optimization for faster modelling?

robjhyndman commented 5 years ago

It is not clear what you mean, or why you think Bayesian approach would be faster. In general, Bayesian approaches are slower than frequentist approaches. Also, what model are you referring to, and what Bayesian optimization scheme?

rohan-gt commented 5 years ago

Sorry, I should've been more clear. Bayesian optimization has been seen to be more efficient than grid search and random search for choosing hyper-parameters for machine learning algorithms (reference). I was wondering if the same principle could be applied to your auto.arima() and ets() functions for example where you're using a grid search to select your hyper-parameters to make them faster. This could further be combined with the tsCV() function to cross-validate the results and further fine tune the parameters

robjhyndman commented 5 years ago

We don't use a grid search or a random search. We use Nelder-Mead in ets() and BFGS in auto.arima(), both of which are quite fast.

There is little point using tsCV to select parameters, unless you want to do order selection or tune parameters for multi-step forecasting. Using tsCV for one-step forecasting will give the same result as MLE with a Gaussian likelihood but much more slowly.