Class Signature
Parameters
Dataset name (e.g., “ett”, “etth1”).
Name of the datetime column in the CSV file.
Path to the CSV file containing time-series data.
Batch size for dataloaders.
Dataset mode: “train” or “test”.
Train/val/test split boundaries. If [0,0,0], uses 50%/20%/30% split.
Task name: “evaluation” or “finetuning”.
Stride for windowing when creating sequences.
Length of historical context to use for forecasting.
Forecast horizon length. Automatically capped at 30% of dataset length.
Whether to normalize the data.
Attributes
Number of channels (columns) in the time series, computed as
df.shape[1] - 1.Methods
get_data_loader()
Returns a PyTorch DataLoader for the dataset.PyTorch DataLoader configured with the specified batch size.
len()
Returns the number of samples in the dataset.Total number of samples available.
Usage Example
Notes
- Horizon length is automatically capped at 30% of the dataset length to prevent overfitting
- Default boundaries use 50%/20%/30% split for train/val/test if not specified
- Data normalization is applied by default
- Datetime column is dropped after reading if specified
- Supports both evaluation and fine-tuning tasks