MarginSampling

class probly.evaluation.active_learning.strategies.MarginSampling[source]

Bases: object

Selects unlabeled samples with the smallest margin between top-2 class probs.

A small margin indicates the model is uncertain between its top two predicted classes, making these samples most informative to label.

select(estimator: Estimator, pool: ActiveLearningPool, n: int) → ArrayLike[source]

Return n indices with the smallest margin in predicted probabilities.

Examples using probly.evaluation.active_learning.strategies.MarginSampling

Active Learning with sklearn - Margin vs Random

Active Learning with sklearn - Margin vs Random

Active Learning with PyTorch - BADGE Selection

Active Learning with PyTorch - BADGE Selection