Hi, I have followed the steps to train my model deterministically here
https://pytorch.org/docs/1.8.1/notes/randomness.html 3
However, I’m unable to reproduce my results. After a single call to backward(), I can see my models begin to diverge. I am attempting to train Faster RCNN on a custom dataset.
I’d be glad to include additional details, but maybe the following is enough to figure out what’s going on. My code includes
 46 def seed_worker(worker_id):
 47     worker_seed = torch.initial_seed() % 2**32
 48     np.random.seed(worker_seed)
 49     random.seed(worker_seed)

As well as a seeding block in the beginning of my main() as follows
109     seed = 1
110     torch.use_deterministic_algorithms(True) # , in beta....
111     torch.backends.cudnn.deterministic = True
112     torch.backends.cudnn.benchmark = False
113     np.random.seed(seed)
114     random.seed(seed)
115     os.environ['PYTHONHASHSEED'] = str(seed)
116     torch.manual_seed(seed)
117     torch.cuda.manual_seed(seed)
118     torch.cuda.manual_seed_all(seed)

Am I missing something here, or is torch.use_determinisitc_algorithms still not working? I have the following versions in python 3.7.4 and CUDA 10.2
torch==1.8.1
torchfile==0.1.0
torchvision==0.9.1