d9e93765aad7a42aafc357fabcd3ef644aa6dde6,implementations/cgan/cgan.py,,sample_image,#,138

Before Change


    // Sample noise
    z = Variable(FloatTensor(np.random.normal(0, 1, (10, opt.latent_dim))))
    // Get labels ranging from 0 to n_classes for n rows
    labels = np.arange(0, 10, 10)
    labels = Variable(LongTensor(labels))
    gen_imgs = generator(z, labels)
    save_image(gen_imgs.data, "images/%d.png" % batches_done, nrow=5, normalize=True)

After Change


    // Sample noise
    z = Variable(FloatTensor(np.random.normal(0, 1, (n_row**2, opt.latent_dim))))
    // Get labels ranging from 0 to n_classes for n rows
    labels = np.array([num for _ in range(n_row) for num in range(n_row)])
    labels = Variable(LongTensor(labels))
    gen_imgs = generator(z, labels)
    save_image(gen_imgs.data, "images/%d.png" % batches_done, nrow=n_row, normalize=True)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 2

Instances


Project Name: eriklindernoren/PyTorch-GAN
Commit Name: d9e93765aad7a42aafc357fabcd3ef644aa6dde6
Time: 2018-04-23
Author: eriklindernoren@gmail.com
File Name: implementations/cgan/cgan.py
Class Name:
Method Name: sample_image


Project Name: librosa/librosa
Commit Name: 499c86371ab8f51528b857902bf54305df6d9606
Time: 2016-06-09
Author: brian.mcfee@nyu.edu
File Name: librosa/display.py
Class Name:
Method Name: __decorate_axis


Project Name: kundajelab/dragonn
Commit Name: 38512d92a8682a62e73c5b9e86366888be374532
Time: 2019-05-29
Author: annashcherbina@gmail.com
File Name: dragonn/vis/__init__.py
Class Name:
Method Name: plot_ism


Project Name: suragnair/alpha-zero-general
Commit Name: 9ba03a34fea5197fd779f708754cf1ddbd718edc
Time: 2020-04-24
Author: 41483463+goshawk22@users.noreply.github.com
File Name: tictactoe_3d/TicTacToePlayers.py
Class Name: HumanTicTacToePlayer
Method Name: play