Skip to content

Glossary: Computer Vision Basics

WeightedRandomSampler

Also written: sampler

A sampler that draws each epoch's photos with probabilities you give it, with replacement, so a rare class turns up more often. You don't also pass `shuffle=True` to the DataLoader.

Where the book teaches it

Related terms

class imbalanceDataLoaderpos_weight