Skip to content
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

input format of training and test data #38

Open
jgerlach93 opened this issue Feb 8, 2022 · 1 comment
Open

input format of training and test data #38

jgerlach93 opened this issue Feb 8, 2022 · 1 comment

Comments

@jgerlach93
Copy link

jgerlach93 commented Feb 8, 2022

Hey,

after running the example successfully, I am trying to feed in custom data.
My feature dataset consists of many time series, of which I would only like to predict a few. The data has a frequency of 5s. All time series are non-negative, but many contain zeros. The time series that I would like to predict are all strictly larger zero.

(i) How would one adapt the code to work with 5s data? I was thinking of a quick fix to simply replace the 5s dates by daily dates? But I would still have to remove the influence of daily seasonality from the model, right?

(ii) Also, when trying to predict on just a subset of the time series by inscribing just those into the y_df, I get an assertion error in line 135 of data.py:

assert batch_y.shape[1]>=1 

(iii) I added +1 to the training and test data to prevent having zero values. Would that be ok?

I don't know whether the discussion here is still ongoing, but I would appreciate any feedback!

Best,
JC

@kdgutier
Copy link
Owner

kdgutier commented Feb 8, 2022

Hi @jgerlach93 ,

In the past we added that assert to protect us against time-series with smaller length than that of inputs and outputs length.
I think the dataset is trying to feed a series that is just too short.
A simple fix would be to drop that short series. Hope it works.

In the NeuralForecast library the job of the windows creation is done by the TSDataset and TSLoader classes:
https://github.com/Nixtla/neuralforecast/blob/main/nbs/data__tsdataset.ipynb
https://github.com/Nixtla/neuralforecast/blob/main/nbs/data__tsloader.ipynb

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants