mirror of
https://github.com/Doctorado-ML/bayesclass.git
synced 2025-08-19 09:35:54 +00:00
Begin with kDB classifier
This commit is contained in:
@@ -69,8 +69,7 @@ def test_TAN_classifier(data):
|
||||
X = data[0]
|
||||
y = data[1]
|
||||
y_pred = clf.predict(X)
|
||||
y = y.reshape(-1, 1)
|
||||
assert y_pred.shape == (X.shape[0], 1)
|
||||
assert y_pred.shape == (X.shape[0],)
|
||||
assert sum(y == y_pred) == 147
|
||||
|
||||
|
||||
@@ -103,8 +102,7 @@ def test_TAN_classifier_simple_init(data):
|
||||
X = data[0]
|
||||
y = data[1]
|
||||
y_pred = clf.predict(X)
|
||||
y = y.reshape(-1, 1)
|
||||
assert y_pred.shape == (X.shape[0], 1)
|
||||
assert y_pred.shape == (X.shape[0],)
|
||||
assert sum(y == y_pred) == 147
|
||||
|
||||
|
||||
|
@@ -7,4 +7,7 @@ from bayesclass import TAN
|
||||
|
||||
@pytest.mark.parametrize("estimator", [TAN()])
|
||||
def test_all_estimators(estimator):
|
||||
return check_estimator(estimator)
|
||||
i = 0
|
||||
for estimator, test in check_estimator(estimator, generate_only=True):
|
||||
print(i := i + 1, test, "classes_")
|
||||
# test(estimator)
|
||||
|
Reference in New Issue
Block a user