

def check_classification_toy(name):
    'Check classification on a toy dataset.'
    ForestClassifier = FOREST_CLASSIFIERS[name]
    clf = ForestClassifier(n_estimators=10, random_state=1)
    clf.fit(X, y)
    assert_array_equal(clf.predict(T), true_result)
    assert_equal(10, len(clf))
    clf = ForestClassifier(n_estimators=10, max_features=1, random_state=1)
    clf.fit(X, y)
    assert_array_equal(clf.predict(T), true_result)
    assert_equal(10, len(clf))
    leaf_indices = clf.apply(X)
    assert_equal(leaf_indices.shape, (len(X), name.n_estimators))

dataset/ETHPy150Open scikit-learn/scikit-learn/sklearn/ensemble/tests/test_forest.py check_classification_toy/VarMisuse@132/179 `clf`->`name`