Explore Library
Code QuizAdvanced

Seeding for Reproducibility

Find the missing piece that leaves torch results non-deterministic.

Codepython
import random
import numpy as np
import torch

def set_seed(seed):
    random.seed(seed)
    np.random.seed(seed)
    return seed

What is the bug in this reproducibility helper?