Commit ada0db43 authored by WuNoah's avatar WuNoah
Browse files

add change

parent b966c248
......@@ -82,6 +82,9 @@ class ScriptClassifierMerge(ScriptClassifier):
auc = np.nan
confusionMatrix = np.transpose(confusion_matrix(test_y, pred_y))
# in case no success individus and confusion matrix will be [[x]]
if (len(confusionMatrix) == 1):
confusionMatrix = np.array([[0, 0], [0, confusionMatrix[0][0]]])
accuracy = accuracy_score(test_y, pred_y)
resultWeight = self.getBestFeatures(model, self.classifier.features, featureMultiGroup)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment