text_plain_output_1.png
import numpy as np # Import library NumPy (Kalkulasi dsb)

import pandas as pd # Import library Pandas (Baca data)

tmp = pd.read_csv('/kaggle/input/predict-student-performance-from-game-play/train.csv', usecols=[0], low_memory=True)
tmp = tmp.groupby('session_id').session_id.agg('count')

labels = pd.read_csv('/kaggle/input/predict-student-performance-from-game-play/train_labels.csv')
labels['session'] = labels['session_id'].str.split('_', expand=True)[0].astype(np.uint64)
labels['q'] = labels['session_id'].str.split('_q', expand=True)[1].astype(int)
labels

labels.dtypes