aNet.ai
Machine Learning/Learning path
0day streak0XP · Lv 1
← 7. Classification
Lesson 4 of 6 8 min · 148 words

Probability-based classification

Thresholds, calibrated probabilities and cross-entropy loss.

A probabilistic classifier outputs , and you turn it into a decision with a threshold : predict positive if . 0.5 is the default, but not always the best.

Change the threshold to reflect costs. For cancer screening, a missed case is far worse than a false alarm, so lower to catch more positives (higher recall, lower precision). For spam, flagging a real email is costly, so raise .

Calibration means the probabilities are honest: of all emails given 0.8, about 80% really are spam. Logistic regression is usually well calibrated; trees, SVMs and deep networks often are not and can be fixed with Platt scaling or isotonic regression.

The loss used for probabilities is cross-entropy: . It rewards confidence when right and punishes confident mistakes severely.

Formula to remember

Softmax

K scores to K probabilities that sum to 1.

Quick check · +5 XP

In logistic regression, eʷʲ is the factor by which… multiply when xⱼ increases by 1.

Practice this topic
Saved in this browser as you type.
aNet.ai · Introduction to Machine Learning · NewUU course outlineProgress saved in this browser