How does a neural network assign outputs - is there an intrinsic threshold value?
Show older comments
I have a neural network in MATLAB that assigns output to either yes or no (1 or 0) target values. The numbers I get for True Positives, False Positives, True Negatives and False Negatives in the confusion plot are different to the corresponding numbers if I calculate them in the way I would expect they were calculated. I have tried this on a dataset consisting entirely of training data in order to avoid any problems with random data ordering.
Output is a 2xR matrix where R is total records. Each entry is between 0 and 1. Let the output values for record i be O(1,i) and O(2,i).
My first intuition was that if O(1,i) > O(2,i) output will be assigned to class 1, and if O(2,i) > O(1,i) output will be assigned to class 2.
Apparently not so.
My second attempt ignores the output value of class 2, and assigns to class 1 if O(1,i) > 0.5 and class 2 if O(1,i) < 0.5.
Also not the case - though gave an answer close to my first attempt.
Does anyone know how the network actually determines which class the output belongs to? Would be so grateful if you could tell me.
Accepted Answer
More Answers (0)
Categories
Find more on Deep Learning Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!