Search code examples
neural-networkdigitmnist

Recognize Non-Digits


I've programmed a neural network for recognizing single digits which are pushed to my server. I worked pretty well, until customers started to push "empty digits". First I started just iterating manually over them and checking for NOT WHITE. Now it gets even more complicated, as "dirty" blanks are uploaded which have some noise in them. Addiotional some people started to push diagonal & horizontal lines or X's instead of writing 0 (zero).

I wonder how I am supposed to train a "pre"-neural network which classifies these "not digits" Especially I struggle to find a way of training the zeroes depicted by a noisy blank.


Solution

  • You're using a neural network, what I'd suggest is make the neural network output the probability of the input being a given class, e.g. it may output digit 5, certainty 75%.

    Once you have those probabilities, you can work on finding a "cutoff" value below which you'd consider the input as being just noise/empty.

    I've linked above to a question about getting the classification probabilities out of a NN.