Sulba
ReviewSign inAccount
Theme
Editor theme
Light
Dark

Beginner · The maths behind ML, as code

Sampling

Draw the random batches a model trains on, in NumPy: shuffle every epoch, work out how far a batch's average strays from the whole, balance the classes by weighted sampling, and share each epoch's batches out across workers.

You build
sampling.py, then batches.py
Stages
3 Build, 1 Catch, 1 Ship
Time
About 3.5 hours

Loading the workspace…