def test_feature_selection(self):
    df = load_bank()
    df = cudf.from_pandas(df)
    y = df.pop('y')
    p = int((df.shape[0] * 0.8))
    X_train = df[:p]
    X_test = df[p:]
    selector = dd_selector(remove_shift_variable=False, auc_threshold=0.55, min_features=15, remove_size=0.2)
    (remain_features, history, scores) = selector.select(X_train, X_test, copy_data=True)
    assert (len(remain_features) == 15)
    selector = dd_selector(remove_shift_variable=True, auc_threshold=0.55, min_features=15, remove_size=0.2)
    (remain_features, history, scores) = selector.select(X_train, X_test, copy_data=True)
    assert (len(remain_features) == 16)
def test_feature_selection(self):
    df = load_bank()
    df = cudf.from_pandas(df)
    y = df.pop('y')
    p = int((df.shape[0] * 0.8))
    X_train = df[:p]
    X_test = df[p:]
    selector = dd_selector(remove_shift_variable=False, auc_threshold=0.55, min_features=15, remove_size=0.2)
    (remain_features, history, scores) = selector.select(X_train, X_test, copy_data=True)
    assert (len(remain_features) == 15)
    selector = dd_selector(remove_shift_variable=True, auc_threshold=0.55, min_features=15, remove_size=0.2)
    (remain_features, history, scores) = selector.select(X_train, X_test, copy_data=True)
    assert (len(remain_features) == 16)