zalandoresearch / pytorch-ts

PyTorch based Probabilistic Time Series forecasting framework based on GluonTS backend
MIT License
1.21k stars 190 forks source link

get_dataset() function failing #46

Closed larkz closed 3 years ago

larkz commented 3 years ago

get_dataset() function failing with call

dataset = get_dataset("pts_m5", regenerate=False)

Fails with error message,

---------------------------------------------------------------------------
AssertionError                            Traceback (most recent call last)
<ipython-input-6-3674bc0c6fce> in <module>
----> 1 dataset = get_dataset("pts_m5", regenerate=False)

~/code/geo-deep-forecast/.geo-deep-env3.8-v5/lib/python3.8/site-packages/gluonts/dataset/repository/datasets.py in get_dataset(dataset_name, path, regenerate)
    189         dataset obtained by either downloading or reloading from local file.
    190     """
--> 191     dataset_path = materialize_dataset(dataset_name, path, regenerate)
    192 
    193     return load_datasets(

~/code/geo-deep-forecast/.geo-deep-env3.8-v5/lib/python3.8/site-packages/gluonts/dataset/repository/datasets.py in materialize_dataset(dataset_name, path, regenerate)
    142         the path where the dataset is materialized
    143     """
--> 144     assert dataset_name in dataset_recipes.keys(), (
    145         f"{dataset_name} is not present, please choose one from "
    146         f"{dataset_recipes.keys()}."

AssertionError: pts_m5 is not present, please choose one from odict_keys(['constant', 'exchange_rate', 'solar-energy', 'electricity', 'traffic', 'exchange_rate_nips', 'electricity_nips', 'traffic_nips', 'solar_nips', 'wiki-rolling_nips', 'taxi_30min', 'm3_monthly', 'm3_quarterly', 'm3_yearly', 'm3_other', 'm4_hourly', 'm4_daily', 'm4_weekly', 'm4_monthly', 'm4_quarterly', 'm4_yearly', 'm5']).
kashif commented 3 years ago

to get the pytorch-ts M5 dataset kindly do:

from pts.dataset.repository.datasets import dataset_recipes

# and then:
dataset = get_dataset("pts_m5", regenerate=False)