Ask Your Question

How to get the confidence value of detections got through ANN_MLP?

asked 2017-01-30 03:31:55 -0500

esha gravatar image

I have got too many detections through neural network classifier. Hence I want to reject some of them based on the confidence value of each detection. Kindly help me to get the parameter which can give me the confidence value of each detection.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2017-01-31 02:16:09 -0500

berak gravatar image

updated 2017-01-31 02:18:40 -0500

you can pass a result mat to ann->predict(), which will hold the logit values from the last layer:

Mat result;
float predicted = ann->predict(query, result);
cerr << predicted << " " << result << endl;

for N classes (output neurons), you will receive an [Nx1] float mat, the prediction value is derived from that internally by calling minMaxLoc().

edit flag offensive delete link more


yes, but sometimes the logit output is greater than 1...How you can determine a sort of confidence?

alexMm1 gravatar imagealexMm1 ( 2017-05-24 04:05:12 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2017-01-30 03:31:55 -0500

Seen: 125 times

Last updated: Jan 31 '17