Beyond Binary Classification
Binary classification involves only two classes (e.g., Yes/No, Spam/Not Spam).
Beyond binary classification refers to classification problems where the output has more than two categories.
᪅ Types of Classification Beyond Binary
1. Multiclass Classification
In multiclass classification, each input belongs to one and only one class out of many.
쮽큌 Example:
- Handwritten digit recognition (0᎓9)
- Classifying animals: Dog, Cat, Horse
- Predicting student grade: A, B, C, D
쮽킹 Algorithms used:
- Decision Tree
- Random Forest
- Naïve Bayes
- SVM (with multiclass strategies)
- Neural Networks
2. Multilabel Classification
In multilabel classification, one input can belong to multiple classes simultaneously.
쮽큌 Example:
- Movie genre prediction (Action + Comedy)
- Email tagging (Work + Important + Urgent)
- Image classification (Car + Road + Person)
3. Hierarchical Classification
Classes are organized in a tree-like hierarchy.
쮽큌 Example:
- Animal ᔒ Mammal ᔒ Dog ᔒ Labrador
- Document classification: Science ᔒ Computer Science ᔒ AI
᪅ Approaches to Handle Multiclass Classification
1. One-vs-Rest (OvR)
- Train one classifier per class
- Each classifier separates one class from all others
2. One-vs-One (OvO)
- Train classifiers for every pair of classes
- Best suited for SVM-based models
᪅ Performance Metrics Beyond Binary
For multiclass and multilabel classification, we use:
- Confusion Matrix (multiclass)
- Macro Precision / Recall / F1
- Micro Precision / Recall / F1
- Weighted F1-score
- Hamming Loss (for multilabel)