(self)
| 12 | self.assertGreaterEqual(StrictVersion(xgboost.__version__), StrictVersion("1.2.1")) |
| 13 | |
| 14 | def test_classifier(self): |
| 15 | X_train = np.random.random((100, 28)) |
| 16 | y_train = np.random.randint(10, size=(100, 1)) |
| 17 | X_test = np.random.random((100, 28)) |
| 18 | y_test = np.random.randint(10, size=(100, 1)) |
| 19 | |
| 20 | xgb1 = XGBClassifier(n_estimators=3, use_label_encoder=False, eval_metric='mlogloss') |
| 21 | xgb1.fit( |
| 22 | X_train, y_train, |
| 23 | eval_set=[(X_train, y_train), (X_test, y_test)], |
| 24 | ) |
| 25 | self.assertIn("validation_0", xgb1.evals_result()) |
nothing calls this directly
no outgoing calls
no test coverage detected