(seed)
| 346 | return psnr_test_iter |
| 347 | |
| 348 | def setup_seed(seed): |
| 349 | torch.manual_seed(seed) |
| 350 | torch.cuda.manual_seed_all(seed) |
| 351 | np.random.seed(seed) |
| 352 | random.seed(seed) |
| 353 | torch.backends.cudnn.deterministic = True |
| 354 | |
| 355 | if __name__ == "__main__": |
| 356 | # Set up command line argument parser |