What is One-vs-Rest (OvR) and One-vs-One (OvO) in multi-class classification?

Updated May 17, 2026

Short answer

OvR trains one classifier per class vs all others, while OvO trains classifiers for every pair of classes.

Deep explanation

In One-vs-Rest (OvR), for K classes, K binary classifiers are trained, each distinguishing one class from the rest. In One-vs-One (OvO), K*(K-1)/2 classifiers are trained, each distinguishing between a pair of classes. OvR is simpler and scalable, while OvO can perform better with complex class boundaries but is computationally heavier. Libraries like SVM often use OvO by default due to better decision boundary separation.

Real-world example

Digit classification (0–9) using SVMs where each digit is separated from others or pairwise compared.

Common mistakes

  • Assuming OvR and OvO give identical performance regardless of dataset complexity.

Follow-up questions

  • Why does SVM often use OvO by default?
  • Which approach scales better?

More Supervised Learning interview questions

View all →