text_plain_output_1.png image_output_3.png image_output_2.png image_output_1.png
import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)

train = pd.read_csv('../input/tabular-playground-series-mar-2022/train.csv')
test = pd.read_csv('../input/tabular-playground-series-mar-2022/test.csv')

train = train.set_index('row_id')
test = test.set_index('row_id')

train.time = pd.to_datetime(train.time)
test.time = pd.to_datetime(test.time)

x_unique = train.x.unique()
y_unique = train.y.unique()
d_unique = train.direction.unique()

train_min_time = train.time.min()
train_max_time = train.time.max()
test_min_time = test.time.min()
test_max_time = test.time.max()

congestion_mean = train.congestion.mean()
print(f'congestion {congestion_mean}')