Skip to content

Commit

Permalink
torch.manual_seed also seeds all CUDA devices
Browse files Browse the repository at this point in the history
  • Loading branch information
Cysu committed Aug 28, 2017
1 parent 0c89e7d commit a1df21b
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 3 deletions.
1 change: 0 additions & 1 deletion examples/oim_loss.py
Expand Up @@ -71,7 +71,6 @@ def get_data(name, split_id, data_dir, height, width, batch_size, workers,
def main(args):
np.random.seed(args.seed)
torch.manual_seed(args.seed)
torch.cuda.manual_seed_all(args.seed)
cudnn.benchmark = True

# Redirect print to both console and log file
Expand Down
1 change: 0 additions & 1 deletion examples/softmax_loss.py
Expand Up @@ -70,7 +70,6 @@ def get_data(name, split_id, data_dir, height, width, batch_size, workers,
def main(args):
np.random.seed(args.seed)
torch.manual_seed(args.seed)
torch.cuda.manual_seed_all(args.seed)
cudnn.benchmark = True

# Redirect print to both console and log file
Expand Down
1 change: 0 additions & 1 deletion examples/triplet_loss.py
Expand Up @@ -73,7 +73,6 @@ def get_data(name, split_id, data_dir, height, width, batch_size, num_instances,
def main(args):
np.random.seed(args.seed)
torch.manual_seed(args.seed)
torch.cuda.manual_seed_all(args.seed)
cudnn.benchmark = True

# Redirect print to both console and log file
Expand Down

0 comments on commit a1df21b

Please sign in to comment.