which means that n_correct is array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]) which fill throw the exception at float(n_correct) / ..
This could be avoided if np.sum() would be used instead the build in function sum()
And just as a side node: The values are real values. How can one tell that output should be e.g. x = [int(v > 0.5) for v in x] to have a binary output that gets compared to the binary encoded target?
I posted this question on stackoverflow but I think that the problem comes from
pybrain.tools.validation.Validator.classificationPerformance()
Because:
which means that
n_correct
isarray([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0])
which fill throw the exception atfloat(n_correct) / ..
This could be avoided if
np.sum()
would be used instead the build in functionsum()
And just as a side node: The values are real values. How can one tell that
output
should be e.g.x = [int(v > 0.5) for v in x]
to have a binaryoutput
that gets compared to the binary encodedtarget
?