torch_timeseries.dataloader.SlidingWindow
- class SlidingWindow(dataset: TimeSeriesDataset, scaler: Scaler, window: int = 168, horizon: int = 3, steps: int = 2, scale_in_train=False, shuffle_train=True, batch_size: int = 32, train_ratio: float = 0.7, val_ratio: float = 0.2, num_worker: int = 3, uniform_eval=True)[source]
Bases:
objectClass for splitting the dataset sequentially and then randomly sampling from each subset.
- dataset
Time series dataset to be used.
- Type:
TimeSeriesDataset
- scaler
Scaler to normalize the data.
- Type:
Scaler
- train_loader
DataLoader for the training data.
- Type:
DataLoader
- val_loader
DataLoader for the validation data.
- Type:
DataLoader
- test_loader
DataLoader for the test data.
- Type:
DataLoader