the last 730 of 1,255 points
Catalog / Time series
M5 Forecasting (Walmart) (2020)
Five years of daily sales for 3,049 Walmart products in 10 stores. Most days, most items sell nothing.
Why it matters
M5 brought the M competitions to Kaggle and to real retail data, with all its awkwardness: intermittent demand, a hierarchy from single item to all of Walmart, prices and holidays. More than 5,000 teams entered. The lesson was the reverse of M4's: gradient-boosted trees (LightGBM) trained on all series at once beat both statistical methods and deep networks, as long as the features were good.
Get the data
# pip install -U huggingface_hub
hf download autogluon/chronos_datasets --repo-type dataset \
--local-dir m5from datasets import load_dataset # pip install datasets
ds = load_dataset("autogluon/chronos_datasets", "m5")
print(ds)import polars as pl
df = pl.read_parquet("hf://datasets/autogluon/chronos_datasets@~parquet/m5/train/*.parquet")
print(df.shape)The Chronos copy: one row per item-store series, with its ids. The calendar and price files are on Kaggle.
- Year
- 2020
- Creators
- Spyros Makridakis, Evangelos Spiliotis, Vassilios Assimakopoulos, with Walmart, on Kaggle
- Task
- Hierarchical forecasting of daily unit sales, 28 days ahead
- Size
- 30,490 item-store series of 1,969 days (2011-01-29 to 2016-06-19)
- Splits
- train 30,490
- Input
- Daily unit sales history, plus a calendar (holidays, SNAP benefit days) and weekly prices
- Labels
- Unit sales for each of the next 28 days, scored at 12 levels of aggregation
- License
- Kaggle competition data
- Paper
- M5 accuracy competition: Results, findings, and conclusions
Samples
the last 730 of 1,609 points
the last 730 of 1,961 points
the last 730 of 1,257 points
the last 730 of 1,963 points
the last 730 of 1,969 points
the last 730 of 1,247 points
the last 730 of 1,967 points
the last 730 of 1,599 points
the last 730 of 1,596 points
the last 730 of 1,966 points
What one record actually looks like (raw JSON, row 14244)
{
"cat_id": "FOODS",
"dept_id": "FOODS_3",
"id": "FOODS_3_815_TX_1",
"item_id": "815",
"state_id": "TX",
"store_id": "TX_1",
"target": [0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, … 690 more],
"timestamp": ["2014-06-21T00:00:00", "2014-06-22T00:00:00", "2014-06-23T00:00:00", "2014-06-24T00:00:00", "2014-06-25T00:00:00", "2014-06-26T00:00:00", "2014-06-27T00:00:00", "2014-06-28T00:00:00", "2014-06-29T00:00:00", "2014-06-30T00:00:00", "2014-07-01T00:00:00", "2014-07-02T00:00:00", "2014-07-03T00:00:00", "2014-07-04T00:00:00", "2014-07-05T00:00:00", "2014-07-06T00:00:00", "2014-07-07T00:00:00", "2014-07-08T00:00:00", "2014-07-09T00:00:00", "2014-07-10T00:00:00", "2014-07-11T00:00:00", "2014-07-12T00:00:00", "2014-07-13T00:00:00", "2014-07-14T00:00:00", "2014-07-15T00:00:00", "2014-07-16T00:00:00", "2014-07-17T00:00:00", "2014-07-18T00:00:00", "2014-07-19T00:00:00", "2014-07-20T00:00:00", "2014-07-21T00:00:00", "2014-07-22T00:00:00", "2014-07-23T00:00:00", "2014-07-24T00:00:00", "2014-07-25T00:00:00", "2014-07-26T00:00:00", "2014-07-27T00:00:00", "2014-07-28T00:00:00", "2014-07-29T00:00:00", "2014-07-30T00:00:00", … 690 more]
}Media fields point at a local copy; on Hugging Face they are bytes in a Parquet file.
Sampled 2026-11-14 from autogluon/chronos_datasets at revision eeecad0
Worth knowing
- The stores are in three states: four in California, three in Texas and three in Wisconsin.
- The products fall into three categories (Foods, Hobbies, Household) and seven departments.
- Scoring covers 42,840 series: the 30,490 item-store series plus every aggregate, up to total sales.
- The sales are intermittent: many items have long runs of zero days, which breaks methods that assume smooth series.
- Christmas Day is the one day every store is closed, so all sales drop to zero.
- The samples show the last two years (730 days) of each series.
Related datasets
- M4 Competition: 2018, 100,000 seriesM4 Competition on this site →
- M5 Uncertainty: the sister competition: forecast nine quantileskaggle.com ↗
- Favorita Grocery Sales: 2017, an earlier Kaggle retail-sales forecasting setkaggle.com ↗