Train inactive class in classification AI problem
I'm facing an issue. I want to classify data in n classes. But, I also want to say that, the answer is none of these n classes.

For example, my classes are : HORSE, CAT, DOG. So I will train with data related to HORSE, CAT and DOG. 

But if I give my model something else, just like a car, I would like my model to tell that it is not HORSE or DOG or CAT. 
So maybe I have to train a model with these classes : HORSE, CAT, DOG, OTHER ?

But If I train OTHER class with data, how can I be sure that if I give it something new like a spacerocket, the prediction will be active for the OTHER class ?

In other words, I'm in trouble with inactive class. I don't want my model to give "the best prediction" beetween my desired classes, I also want it to tell me if it is none of them.

Thank you !

I had some answer, and it seems that there are 2 main solutions for this problem :


As I thought, I can train my classes and 1 more for the other cases. To be robust, I have to create data for this class that my model may have in input to cover as much as cases as possible !
Train n classifier : 1 binary classifier for 1 class. Each one have these outputs : Active / Not Active.


For each solution, I think it is necessary to create dataset for the "other cases", even in the second one to avoid uncontained prediction. In Solution 1, you can choose if you want 1 active class (softmax) or several active classes (sigmoid), in solution 2, it seems harder to control this behavior as each classifier is independent and several classes could be active.

source
