Dataset Preparation for Bakery dataset for Meta-Learning

Some pre-processings steps implemented to prepare the bakery dataset for meta-learning

source

BakeryDatasetLoader

 BakeryDatasetLoader (data_path, overwrite=False,
                      product_as_feature=False, store_as_features=False)

Class to download the Kaggle M5 dataset and apply some preprocessing steps to prepare it for application in inventory management.

run_test = False
if run_test:
    data_path = "/Users/magnus/Documents/02_PhD/03_Newsvendor_foundation_model/experiments/datasets/raw/bakery" # For testing purposes, please specify the path to the data on your machine
    if data_path is not None:
        loader = BakeryDatasetLoader(data_path, overwrite=False, product_as_feature=False, store_as_features=False)
        demand, SKU_features, time_features, time_SKU_features, mask = loader.load_dataset()
INFO:root:Importing data
INFO:root:Preprocessing data
INFO:root:--Creating catogory mapping and features
INFO:root:--Preparing calendric information
INFO:root:--Preparing demand
INFO:root:--Preparing SKU-specific features
INFO:root:--Preparing SKU-time-specific features