From b56eb541a65d31d7027c19726df2b9ebc9b6f7ad Mon Sep 17 00:00:00 2001 From: Francois Caud Date: Fri, 22 Dec 2023 18:23:39 +0100 Subject: [PATCH] clean problem --- problem.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/problem.py b/problem.py index a78e2dc..4d82e58 100644 --- a/problem.py +++ b/problem.py @@ -152,7 +152,6 @@ def _get_data(path=".", split="train"): X_traces = data_df.loc[:, traces] X_df = pd.concat([X_majors, X_traces], axis=1) - # if split == "train": X_df["groups"] = SampleID.tolist() X = X_df @@ -181,16 +180,6 @@ def get_test_data(path="."): return _get_data(path, "test") -# def get_groups(path="."): -# data = pd.read_csv(os.path.join(path, "data", "train.csv")) -# data_df = data.copy() -# data_df["SampleID"] = data_df["SampleID"].astype("category") -# SampleID = np.array(data_df["SampleID"].cat.codes) -# groups = SampleID -# return groups - - def get_cv(X, y): - # groups = get_groups() cv = StratifiedGroupKFold(n_splits=2, shuffle=True, random_state=2) return cv.split(X, y, groups)