7d8f3f66495979f1bbd27205d422d673991709f2,GANs/stylegan2/generate.py,,synthesis,#,28
Before Change
if i > 4:
inmaps = inmaps // 2
noise = nn.Variable.from_numpy_array(rnd.randn(*curr_shape))
h = conv_block(h, w[(2+i)*2-4], noise, res=2 ** (i + 2), outmaps=outmaps, inmaps=inmaps,
kernel_size=3, pad_size=1, namescope="Conv1")
// toRGB blocks
prev_torgb = upsample_2d(torgb, k=[1, 3, 3, 1])
curr_torgb = conv_block(h, w[(2+i)*2-3], noise=None, res=2 ** (i + 2), outmaps=3, inmaps=inmaps,
kernel_size=1, pad_size=0, demodulate=False, namescope="ToRGB", act=F.identity)
torgb = curr_torgb + prev_torgb
return torgb
After Change
outmaps = outmaps // 2
curr_shape = (1, 1, 2 ** (i + 2), 2 ** (i + 2))
noise = nn.Variable.from_numpy_array(rnd.randn(*curr_shape))
h = conv_block(h, w_1, noise, res=2 ** (i + 2), outmaps=outmaps, inmaps=inmaps,
kernel_size=3, up=True, namescope="Conv0_up")
if i > 4:
inmaps = inmaps // 2
noise = nn.Variable.from_numpy_array(rnd.randn(*curr_shape))
h = conv_block(h, w_2, noise, res=2 ** (i + 2), outmaps=outmaps, inmaps=inmaps,
kernel_size=3, pad_size=1, namescope="Conv1")
// toRGB blocks
prev_torgb = upsample_2d(torgb, k=[1, 3, 3, 1])
curr_torgb = conv_block(h, w_3, noise=None, res=2 ** (i + 2), outmaps=3, inmaps=inmaps,
kernel_size=1, pad_size=0, demodulate=False, namescope="ToRGB", act=F.identity)
torgb = curr_torgb + prev_torgb
return torgb
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 3
Instances
Project Name: sony/nnabla-examples
Commit Name: 7d8f3f66495979f1bbd27205d422d673991709f2
Time: 2021-01-26
Author: Krishna.Wadhwani@sony.com
File Name: GANs/stylegan2/generate.py
Class Name:
Method Name: synthesis
Project Name: sony/nnabla-examples
Commit Name: 9dab8ae56ce90f1b9ba6808a6e0673ab6f13103e
Time: 2020-12-15
Author: Krishna.Wadhwani@sony.com
File Name: GANs/stylegan2/generate.py
Class Name:
Method Name: synthesis