OneVersusOne.md (1187B)
1 # One Versus One (OvO) 2 3 ML D2 4 5 **Definition:** A one versus one classification strategy trains binary classifiers to output the probability of an input being part of one class or another. 6 7 Basically, you train a model to compare between one set and another. It outputs the probability of one output over the other. Then by doing these comparisons whichever class wins with the most classifiers the input is part of that class(in theory). 8 9 As such, one must train N * (N-1)/2 classifiers which can be a lot depending on how many classes there are. In the case of 0-9 (mnist) this comes out to 45 models. On the flip side, given how the model works, each model does not need to be trained on the entire set only the subset containing the classes being compared. 10 11 See also [OneVersusAll](OneVersusAll.md) for another strategy regarding classification based on binary classifier chaining. The main reason OvO can be better than OvA is because some models are slow to train on larger datasets thus only training models on a subset, albeit training more models, can be faster. This is especially true for support vector machine classification models. In most cases however OvA is preferred.