Hi everyone, I need a bit of help with how I shou...
# neural-forecast
a
Hi everyone, I need a bit of help with how I should approach this in the best way. I have a dataset with 225 series, each of which has a different length, ranging from a minimum of 50 days to a maximum of 568 days. I am very confused about how to proceed. Any help in this regard would be greatly appreciated. Thanks!
m
Hello! Your question is a bit vague; what do you need exactly? With neuralforecast, you can train models on series with different lengths, but you will be limited by your shortest series.
1
a
Thanks for the reply. You are right; it’s a bit vague, and I need to be more specific. Let’s say the shortest series has 50 data points. How should I define the cross-validation in this case? I have an input size of 35 and a horizon of 15. What would my window size be in this scenario? I’m also a bit confused about the hyperparameters I need to set for cross-validation.
m
In that case, you would either use
n_windows=1
and set
test_size=None
or use
test_size=15
and set
n_windows=None
. Since your series is really short, then I would set
refit=False
, since you don't have more than 1 window to refit anyway.
👍 1
a
Okay, thanks! The follow-up question would be: this is for the short series. What happens when it goes to the larger series, since there are also larger series in the dataset, like, for example, 530 datapoints? So, when I have n_windows=1, it will again take 35 datapoints from the 530 and predict the next 15. The confusion for me comes with n_windows=1. How does the window size influence the longer series? What if the series is ending and you don’t have the 15 datapoints to predict? What will happen then? Will it just predict on the remaining data?
After trying out both ways I always get: Exception: No windows available for training. And that was actually my problem. Any idea where the problem could be?
m
You can either reduce the horizon and input size, or get rid of your shortest series. You can also see how cross-validation works in our tutorial.