From 0ea71ecc7728cfed71f177df54b1b9bafdc2caa1 Mon Sep 17 00:00:00 2001 From: Wok Date: Sat, 19 Sep 2020 14:49:23 +0200 Subject: [PATCH] Retro-compatibility (no manual seed by default) --- apply_factor.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apply_factor.py b/apply_factor.py index d60a7e5b..9bf7f0ed 100755 --- a/apply_factor.py +++ b/apply_factor.py @@ -67,7 +67,8 @@ trunc = g.mean_latent(4096) - torch.manual_seed(torch_seed) + if torch_seed > 0: + torch.manual_seed(torch_seed) latent = torch.randn(args.n_sample, 512, device=args.device) latent = g.get_latent(latent)