text_html_output_2.png text_html_output_1.png text_plain_output_1.png
import numpy as np

import pandas as pd

import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import tensorflow as tf
train = pd.read_csv('../input/tabular-playground-series-sep-2022/train.csv')
test = pd.read_csv('../input/tabular-playground-series-sep-2022/test.csv')
ss = pd.read_csv('../input/tabular-playground-series-sep-2022/sample_submission.csv')

cols = ['country', 'store', 'product']

cnt_val = pd.unique(train['country'])
str_val = pd.unique(train['store'])
prod_val = pd.unique(train['product'])
data = np.empty(shape=48, dtype='object')
print(data.shape)
i = 0
for x in cnt_val:
    for y in str_val:
        for z in prod_val:
            data[i] = train[(train['country'] == x) & (train['store'] == y) & (train['product'] == z)]
            i += 1
display(data[0])
display(data[7])