Kaggle competition: Jane Street Market Prediction
<groupby><EOS> 
data = pd.read_csv('/kaggle/input/jane-street-market-prediction/train.csv')
 data=data[data.weight!=0]
NAN_VALUE = -9999
features = [c for c in data.columns if 'feature' in c]
target = 'resp'
X = data.loc[:, features].fillna(NAN_VALUE)
 Y =(data.loc[:, target] > 0 ).astype(int)
 del data
gc.collect()
model = xgb.XGBClassifier(
 n_estimators=500,
max_depth=11,
learning_rate=0.05,
subsample=0.9,
colsample_bytree=0.7,
missing=NAN_VALUE,
random_state=2020,
tree_method='gpu_hist',
nthread=multiprocessing.cpu_count() 
)
 model.fit(X, Y)
 print('Finished training model')
 del X, Y
gc.collect()
env = janestreet.make_env()
iter_test = env.iter_test()
for(test_df, sample_prediction_df)in iter_test:
X_test = test_df.loc[:, features]
X_test = X_test.fillna(NAN_VALUE)
 sample_prediction_df.action = model.predict(X_test)
 env.predict(sample_prediction_df )