MSRDL / Deep4Cast

Probabilistic Multivariate Time Series Forecast using Deep Learning
BSD 3-Clause "New" or "Revised" License
94 stars 22 forks source link

Enable predict function to generate only one prediction when uncertainty is not needed, for speed up purpose. #35

Closed shirleyuw closed 6 years ago

shirleyuw commented 6 years ago

The motivation is to speed up prediction when running on a list of benchmark datasets. The predict() function in Forecaster() class used to always predict 100 samples and return mean, quantiles and samples. To speed up, we only predict one sample when the uncertainty argument in Forecaster() is False, when uncertainty is not needed by the user.

shirleyuw commented 6 years ago

Changed to inline ifs; Changed to always return the same set of variables. When uncertainty is not required, it returns None for the quantile results.