Random Seeds and Reproducibility

Setting up your experiments in Python, Numpy, and PyTorch

Daniel Godoy
Towards Data Science
15 min readMay 13, 2022

--

Photo by Christian Joudrey on Unsplash

Motivation

"What is a programmer's worst nightmare?"

On my part, I can safely say that my worst nightmare, as a programmer, is a piece of code that behaves as if it were random, spewing out different results every time I run it, even if I give it the very

--

--

Data Scientist, developer, teacher and writer. Author of "Deep Learning with PyTorch Step-by-Step: A Beginner’s Guide" https://pytorchstepbystep.com