Receiving KeyError: "None of [Int64Index([ ... dtype='int64', length=1323)] are in the [columns]"
in this piece of code train, test
are arrays of indices, while you using it as a columns when selection from DataFrame:
for train, test in kf.split(X, Y): probas_ = model.fit(X[train], Y[train]).predict_proba(X[test])
you should use iloc
instead:
probas_ = model.fit(X.iloc[train], Y.iloc[train]).predict_proba(X.iloc[test])