DCGAN-tensorflow - A tensorflow implementation of Deep Convolutional Generative Adversarial Networks

Overview

DCGAN in Tensorflow

Tensorflow implementation of Deep Convolutional Generative Adversarial Networks which is a stabilize Generative Adversarial Networks. The referenced torch code can be found here.

alt tag

  • Brandon Amos wrote an excellent blog post and image completion code based on this repo.
  • To avoid the fast convergence of D (discriminator) network, G (generator) network is updated twice for each D network update, which differs from original paper.

Online Demo

link

Prerequisites

Usage

First, download dataset with:

$ python download.py mnist celebA

To train a model with downloaded dataset:

$ python main.py --dataset mnist --input_height=28 --output_height=28 --train
$ python main.py --dataset celebA --input_height=108 --train --crop

To test with an existing model:

$ python main.py --dataset mnist --input_height=28 --output_height=28
$ python main.py --dataset celebA --input_height=108 --crop

Or, you can use your own dataset (without central crop) by:

$ mkdir data/DATASET_NAME
... add images to data/DATASET_NAME ...
$ python main.py --dataset DATASET_NAME --train
$ python main.py --dataset DATASET_NAME
$ # example
$ python main.py --dataset=eyes --input_fname_pattern="*_cropped.png" --train

If your dataset is located in a different root directory:

$ python main.py --dataset DATASET_NAME --data_dir DATASET_ROOT_DIR --train
$ python main.py --dataset DATASET_NAME --data_dir DATASET_ROOT_DIR
$ # example
$ python main.py --dataset=eyes --data_dir ../datasets/ --input_fname_pattern="*_cropped.png" --train

Results

result

celebA

After 6th epoch:

result3

After 10th epoch:

result4

Asian face dataset

custom_result1

custom_result1

custom_result2

MNIST

MNIST codes are written by @PhoenixDai.

mnist_result1

mnist_result2

mnist_result3

More results can be found here and here.

Training details

Details of the loss of Discriminator and Generator (with custom dataset not celebA).

d_loss

g_loss

Details of the histogram of true and fake result of discriminator (with custom dataset not celebA).

d_hist

d__hist

Related works

Author

Taehoon Kim / @carpedm20

Comments
  • ValueError: Trying to share variable discriminator/d_h3_lin/Matrix, but specified shape (8192, 1) and found shape (25088, 1).

    ValueError: Trying to share variable discriminator/d_h3_lin/Matrix, but specified shape (8192, 1) and found shape (25088, 1).

    Hi,

    When I clone your repo, download the datasets and run the code, this is the error that I get. The issue comes from the assignment of variable h4 in the discriminator when calling the linear() function.

    Any ideas of what the problem might be?

    Thanks!

    opened by MankowitzProjects 16
  • urllib.error.URLError: <urlopen error [Errno 110] Connection timed out>

    urllib.error.URLError:

    Configuration:tensorflow 0.12.1, python3.4.3 ,ubuntu14.04 I have successfully run python download.py mnist and got the mnist data.but when I ran python download.py celebAt ,there was an error : File "/usr/lib/python3.4/urllib/request.py", line 1182, in do_open h.request(req.get_method(), req.selector, req.data, headers) File "/usr/lib/python3.4/http/client.py", line 1125, in request self._send_request(method, url, body, headers) File "/usr/lib/python3.4/http/client.py", line 1163, in _send_request self.endheaders(body) File "/usr/lib/python3.4/http/client.py", line 1121, in endheaders self._send_output(message_body) File "/usr/lib/python3.4/http/client.py", line 951, in _send_output self.send(msg File "/usr/lib/python3.4/http/client.py", line 886, in send self.connect() File "/usr/lib/python3.4/http/client.py", line 1260, in connect super().connect() File "/usr/lib/python3.4/http/client.py", line 863, in connect self.timeout, self.source_address) File "/usr/lib/python3.4/socket.py", line 512, in create_connection raise err File "/usr/lib/python3.4/socket.py", line 503, in create_connection sock.connect(sa) TimeoutError: [Errno 110] Connection timed out

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last): File "download.py", line 140, in download_celeb_a('./data') File "download.py", line 65, in download_celeb_a filepath = download(url, dirpath) File "download.py", line 28, in download u = urllib.request.urlopen(url) File "/usr/lib/python3.4/urllib/request.py", line 161, in urlopen return opener.open(url, data, timeout) File "/usr/lib/python3.4/urllib/request.py", line 463, in open response = self._open(req, data) File "/usr/lib/python3.4/urllib/request.py", line 481, in _open '_open', req) File "/usr/lib/python3.4/urllib/request.py", line 441, in _call_chain result = func(*args) File "/usr/lib/python3.4/urllib/request.py", line 1225, in https_open context=self._context, check_hostname=self._check_hostname) File "/usr/lib/python3.4/urllib/request.py", line 1184, in do_open raise URLError(err) urllib.error.URLError: <urlopen error [Errno 110] Connection timed out>

    anyone has the same error?could someone teach me how to fix it,please?thx a lot!

    opened by pandamax 13
  • sigmoid_cross_entropy_with_logits does not have `labels` arg

    sigmoid_cross_entropy_with_logits does not have `labels` arg

    Hello,

    I'm having some difficulties getting the example code to execute. I believe the issue stems from a tensorflow versioning delta. I first tried to train a model on the celebA data after setting up a cpu tensorflow docker container from: https://hub.docker.com/r/tensorflow/tensorflow/

    When I run

    python main.py --dataset celebA --input_height=108 --is_train --is_crop True
    

    I get the following traceback:

    Traceback (most recent call last):
      File "main.py", line 96, in <module>
        tf.app.run()
      File "/usr/local/lib/python2.7/dist-packages/tensorflow/python/platform/app.py", line 43, in run
        sys.exit(main(sys.argv[:1] + flags_passthrough))
      File "main.py", line 76, in main
        sample_dir=FLAGS.sample_dir)
      File "/root/git_repos/DCGAN-tensorflow/model.py", line 71, in __init__
        self.build_model()
      File "/root/git_repos/DCGAN-tensorflow/model.py", line 115, in build_model
        logits=self.D_logits, labels=tf.ones_like(self.D)))
    TypeError: sigmoid_cross_entropy_with_logits() got an unexpected keyword argument 'labels'
    

    After looking, I found sigmoid_cross_entropy_with_logits here: https://github.com/tensorflow/tensorflow/blob/cb17d1b0e2b581b5da1d9597b7929ba764749d38/tensorflow/python/ops/nn_impl.py#L99 which shows that it does take a labels arg. However, the version under v0.12.1 does not take this arg which I believe is the error I'm receiving above.

    Furthermore, if I try to install the specific version of tensorflow branch that you linked to:

    pip install git+https://github.com/tensorflow/[email protected]
    

    I get the following traceback:

    Collecting git+https://github.com/tensorflow/[email protected]
      Cloning https://github.com/tensorflow/tensorflow.git (to r0.12) to /tmp/pip-oKC0L1-build
        Complete output from command python setup.py egg_info:
        Traceback (most recent call last):
          File "<string>", line 1, in <module>
        IOError: [Errno 2] No such file or directory: '/tmp/pip-oKC0L1-build/setup.py'
    
        ----------------------------------------
    Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-oKC0L1-build/
    

    Any suggestions on how to get this up and running?

    Thanks, Scott

    opened by jscottcronin 13
  • Trying to share variable discriminator/d_h3_lin/Matrix

    Trying to share variable discriminator/d_h3_lin/Matrix

    {'batch_size': 64,
     'beta1': 0.5,
     'checkpoint_dir': 'checkpoint',
     'crop': False,
     'dataset': 'faces',
     'epoch': 25,
     'input_fname_pattern': '*.jpg',
     'input_height': 96,
     'input_width': 96,
     'learning_rate': 0.0002,
     'output_height': 64,
     'output_width': 64,
     'sample_dir': 'samples',
     'train': True,
     'train_size': inf,
     'visualize': False}
    2017-05-02 18:44:49.160149: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
    2017-05-02 18:44:49.160180: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
    2017-05-02 18:44:49.160190: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
    2017-05-02 18:44:49.160197: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX2 instructions, but these are available on your machine and could speed up CPU computations.
    2017-05-02 18:44:49.160204: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use FMA instructions, but these are available on your machine and could speed up CPU computations.
    Traceback (most recent call last):
      File "main.py", line 97, in <module>
        tf.app.run()
      File "/usr/lib/python3.6/site-packages/tensorflow/python/platform/app.py", line 48, in run
        _sys.exit(main(_sys.argv[:1] + flags_passthrough))
      File "main.py", line 75, in main
        sample_dir=FLAGS.sample_dir)
      File "/opt/DCGAN-tensorflow/model.py", line 82, in __init__
        self.build_model()
      File "/opt/DCGAN-tensorflow/model.py", line 118, in build_model
        self.D_, self.D_logits_ = self.discriminator(self.G, reuse=True)
      File "/opt/DCGAN-tensorflow/model.py", line 332, in discriminator
        h4 = linear(tf.reshape(h3, [self.batch_size, -1]), 1, 'd_h3_lin')
      File "/opt/DCGAN-tensorflow/ops.py", line 98, in linear
        tf.random_normal_initializer(stddev=stddev))
      File "/usr/lib/python3.6/site-packages/tensorflow/python/ops/variable_scope.py", line 1049, in get_variable
        use_resource=use_resource, custom_getter=custom_getter)
      File "/usr/lib/python3.6/site-packages/tensorflow/python/ops/variable_scope.py", line 948, in get_variable
        use_resource=use_resource, custom_getter=custom_getter)
      File "/usr/lib/python3.6/site-packages/tensorflow/python/ops/variable_scope.py", line 356, in get_variable
        validate_shape=validate_shape, use_resource=use_resource)
      File "/usr/lib/python3.6/site-packages/tensorflow/python/ops/variable_scope.py", line 341, in _true_getter
        use_resource=use_resource)
      File "/usr/lib/python3.6/site-packages/tensorflow/python/ops/variable_scope.py", line 658, in _get_single_variable
        found_var.get_shape()))
    ValueError: Trying to share variable discriminator/d_h3_lin/Matrix, but specified shape (8192, 1) and found shape (18432, 1).
    
    

    My commond is

    python main.py --dataset faces --input_height=96 --output_height=64 --train
    

    my data file size is 96*96,i'm try many time but always this error. can you help me?

    opened by tusik 12
  • TypeError: Expected int32, got list containing Tensors of type '_Message' instead.

    TypeError: Expected int32, got list containing Tensors of type '_Message' instead.

    run code :

    python main.py --dataset mnist --input_height=28 --output_height=28 --c_dim=1 --is_train 
    

    image

    TypeError: Expected int32, got list containing Tensors of type '_Message' instead.

    opened by fengwei2014 11
  • Issues importing my own dataset

    Issues importing my own dataset

    I have been troubleshooting this for a few days now and I think it's about time to ask. I have tried importing a couple of datasets that I reshaped with PIL to 96x96(RGB).

    When I use one of the datasets and specify the input_height and output_height flags i get this error:

    ....DCGAN-tensorflow-master/utils.py", line 104, in transform im = Image.fromarray(image[j:j+crop_h, i:i+crop_w]) NameError: name 'j' is not defined

    When I specify the --crop flag I get this:

    ....DCGAN-tensorflow-master/utils.py", line 94, in center_crop im = Image.fromarray(x[j:j+crop_h, i:i+crop_w]) File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/PIL/Image.py", line 2517, in fromarray raise TypeError("Cannot handle this data type") TypeError: Cannot handle this data type

    With all this being said, I think it is an issue with my images and the crop function. I have used the mnist dataset and it works fine.

    For reference on what my images are, I have attached two. If you have any advice on what I can change to fix this issue I would really appreciate it.

    000 001

    opened by bencooper96 10
  • Failed to generate test images

    Failed to generate test images

    I started training with: python main.py --input_height 256 --input_width 256 --output_height 64 --output_width 64 --dataset test1 --crop --train --epoch 300 --input_fname_pattern "*.jpg" I tried to generate test images with: python main.py --dataset test1 --input_height 256 --input_width 256 --output_height 64 --output_width 64 --crop However, no test or feedback was generated.

    opened by RuikangSun 7
  • saving training images with batch_size other than 64

    saving training images with batch_size other than 64

    Hi! I managed to train the networks with a custom dataset which contains over 50k samples, and the results are fantastic.

    Then I tried to train another much smaller dataset with 468 images. I thought maybe it'd help to use a smaller batch_size rather than 64 so that I would get more iterations. I changed mod(counter, 100) == 1 to mod(counter, 5) == 1 because I wanted to see more intermediate results. But I got one pic error!... during training. Here's the script I use:

    python main.py --dataset faces --input_height 96 --output_height 48 --c_dim 3 --batch_size 20 --train_size 468 --is_train True --is_crop True --visualize True --epoch 10

    With commenting out the try and except block around line 302-311 to show the exact error messages, I trained again and got the following error:

    ValueError: Cannot feed value of shape (64, 48, 48, 3) for Tensor u'real_images: 0', which has shape '(20, 48, 48, 3)'

    It seems that even with keyword batch_size 20 fed, somewhere in the networks somehow still assumes that batch_size is 64, which causes a value error.

    I haven't further investigated how to resolve this issue, and hope that someone more familiar with the codes could point out for me where to look. Thanks!

    opened by johnhany 7
  • visualize() not able to save the image

    visualize() not able to save the image

    Getting the following error during run:

    Traceback (most recent call last):
      File "main.py", line 96, in <module>
        tf.app.run()
      File "....../tensorflow/python/platform/app.py", line 44, in run
        _sys.exit(main(_sys.argv[:1] + flags_passthrough))
      File "main.py", line 93, in main
        visualize(sess, dcgan, FLAGS, OPTION)
      File "...../DCGAN-tensorflow/utils.py", line 174, in visualize
        save_images(samples, [8, 8], './samples/test_arange_%s.png' % (idx))
      File "....../DCGAN-tensorflow/utils.py", line 26, in save_images
        return imsave(inverse_transform(images), size, image_path)
      File "....../DCGAN-tensorflow/utils.py", line 47, in imsave
        return scipy.misc.imsave(path, merge(images, size))
      File "....../DCGAN-tensorflow/utils.py", line 43, in merge
        img[j*h:j*h+h, i*w:i*w+w, :] = image
    ValueError: could not broadcast input array from shape (64,64,3) into shape (0,64,3)
    
    
    opened by asispatra 7
  • celebA dataset is not accessible

    celebA dataset is not accessible

    I've been trying to download celebA dataset for a couple of weeks now "python download.py celebA", but it always generates the same error: urllib2.HTTPError: HTTP Error 429: Too Many Requests

    opened by IchibanKanobee 7
  • finished implementation of training on mnist dataset

    finished implementation of training on mnist dataset

    I finished implementation of training on mnist dataset and it can run now. However, the g_loss is not converging. I need help from other users to improve the program.

    opened by PhoenixDai 6
  • TypeError: 'NoneType' object is not subscriptable

    TypeError: 'NoneType' object is not subscriptable

    [ WARN:[email protected]] global D:\a\opencv-python\opencv-python\opencv\modules\imgcodecs\src\loadsave.cpp (239) cv::findDecoder imread_('./datasets/mobile_data_img'): can't open/read file: check file path/integrity Traceback (most recent call last): File "main.py", line 146, in tf.app.run() File "C:\Users\For36\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.7_qbz5n2kfra8p0\LocalCache\local-packages\Python37\site-packages\tensorflow\python\platform\app.py", line 125, in run _sys.exit(main(argv)) File "main.py", line 114, in main max_to_keep=FLAGS.max_to_keep) File "C:\Users\For36\Desktop\New folder\DCGAN-tensorflow-master\model.py", line 93, in init imreadImg = imread(self.data[0]) File "C:\Users\For36\Desktop\New folder\DCGAN-tensorflow-master\utils.py", line 56, in imread img_rgb = img_bgr[..., ::-1] TypeError: 'NoneType' object is not subscriptable

    how do i fix this

    opened by breadbrowser 0
  • ValueError: could not broadcast input array from shape (1,2048) into shape (98,1024)

    ValueError: could not broadcast input array from shape (1,2048) into shape (98,1024)

    I'm trying to build a Attention mechanism for Medical report Generation using Chest X-rays.

    train, test = train_test_split(data, test_size = 0.2, random_state = 1, shuffle = True) print(train.shape) - (3056, 4) print(test.shape) - (764, 4)

    Function for Extracting the Images:

    def image_feature_extraction(image1,image2):

      image_1 = Image.open(image1).convert('RGB')
      image_1 = np.asarray(image_1)
    
      image_2 = Image.open(image2).convert('RGB')
      image_2 = np.asarray(image_2)
    
        #normalize the values of the image
      image_1 = image_1/255
      image_2 = image_2/255
    
        #resize all image into (224,224)
      image_1 = cv2.resize(image_1,(224,224))
      image_2 = cv2.resize(image_2,(224,224))
    
      image_1 = np.expand_dims(image_1, axis=0)
      image_2 = np.expand_dims(image_2, axis=0)
    
        #now we have read two image per patient. this is goven to the chexnet model for feature extraction
    
      image_1_out = final_chexnet_model(image_1)
      image_2_out = final_chexnet_model(image_2)
    
      #conactenate along the width
      conc = np.concatenate((image_1_out,image_2_out),axis = -1)
    
      #reshape into(no.of images passed, length*breadth, depth)
      image_feature=tf.reshape(conc,(conc.shape[0], -1, conc.shape[-1]))
      #image_feature = feature_extraction_model([image_1,image_2])
    
      return image_feature
    

    print(image_2_out)

    KerasTensor(type_spec=TensorSpec(shape=(None, 1024), dtype=tf.float32, name=None), name='Chexnet_model/avg_pool/Mean:0', description="created by layer 'Chexnet_model'")

    train_features = np.zeros((3056,98,1024))

    for row in tqdm(range(train.shape[0])): image_1=train.iloc[row]["image1"] image_2=train.iloc[row]["image2"] train_features[row] = (image_feature_extraction(image_1,image_2))

    0%| | 0/3056 [00:00<?, ?it/s]

    ValueError Traceback (most recent call last) in 2 image_1=train.iloc[row]["image1"] 3 image_2=train.iloc[row]["image2"] ----> 4 train_features[row] = (image_feature_extraction(image_1,image_2))

    ValueError: could not broadcast input array from shape (1,2048) into shape (98,1024)

    opened by Hemanth-Gloify 2
  • Can't create checkpoint

    Can't create checkpoint

    I have already checked the previous issues, #338 , #380 , #383 , #369 and I still can't create checkpoint under my checkpoint_dir. The checkpoint and the samples folders remain empty.

    image

    Does anyone know how to solve this? Any advice would be really appreciated. I'm sharing the command and logs :

    command

    python main.py --dataset testdir --input_height 96 --input_width 96 --output_height 96 --output_width 96 --batch_size=1 --train --epoch=300 --ckpt_freq=100 --generate_test_images=10

    logs

    ---------
    Variables: name (type shape) [size]
    ---------
    generator/g_h0_lin/Matrix:0 (float32_ref 100x18432) [1843200, bytes: 7372800]
    generator/g_h0_lin/bias:0 (float32_ref 18432) [18432, bytes: 73728]
    generator/g_bn0/beta:0 (float32_ref 512) [512, bytes: 2048]
    generator/g_bn0/gamma:0 (float32_ref 512) [512, bytes: 2048]
    generator/g_h1/w:0 (float32_ref 5x5x256x512) [3276800, bytes: 13107200]
    generator/g_h1/biases:0 (float32_ref 256) [256, bytes: 1024]
    generator/g_bn1/beta:0 (float32_ref 256) [256, bytes: 1024]
    generator/g_bn1/gamma:0 (float32_ref 256) [256, bytes: 1024]
    generator/g_h2/w:0 (float32_ref 5x5x128x256) [819200, bytes: 3276800]
    generator/g_h2/biases:0 (float32_ref 128) [128, bytes: 512]
    generator/g_bn2/beta:0 (float32_ref 128) [128, bytes: 512]
    generator/g_bn2/gamma:0 (float32_ref 128) [128, bytes: 512]
    generator/g_h3/w:0 (float32_ref 5x5x64x128) [204800, bytes: 819200]
    generator/g_h3/biases:0 (float32_ref 64) [64, bytes: 256]
    generator/g_bn3/beta:0 (float32_ref 64) [64, bytes: 256]
    generator/g_bn3/gamma:0 (float32_ref 64) [64, bytes: 256]
    generator/g_h4/w:0 (float32_ref 5x5x3x64) [4800, bytes: 19200]
    generator/g_h4/biases:0 (float32_ref 3) [3, bytes: 12]
    discriminator/d_h0_conv/w:0 (float32_ref 5x5x3x64) [4800, bytes: 19200]
    discriminator/d_h0_conv/biases:0 (float32_ref 64) [64, bytes: 256]
    discriminator/d_h1_conv/w:0 (float32_ref 5x5x64x128) [204800, bytes: 819200]
    discriminator/d_h1_conv/biases:0 (float32_ref 128) [128, bytes: 512]
    discriminator/d_bn1/beta:0 (float32_ref 128) [128, bytes: 512]
    discriminator/d_bn1/gamma:0 (float32_ref 128) [128, bytes: 512]
    discriminator/d_h2_conv/w:0 (float32_ref 5x5x128x256) [819200, bytes: 3276800]
    discriminator/d_h2_conv/biases:0 (float32_ref 256) [256, bytes: 1024]
    discriminator/d_bn2/beta:0 (float32_ref 256) [256, bytes: 1024]
    discriminator/d_bn2/gamma:0 (float32_ref 256) [256, bytes: 1024]
    discriminator/d_h3_conv/w:0 (float32_ref 5x5x256x512) [3276800, bytes: 13107200]
    discriminator/d_h3_conv/biases:0 (float32_ref 512) [512, bytes: 2048]
    discriminator/d_bn3/beta:0 (float32_ref 512) [512, bytes: 2048]
    discriminator/d_bn3/gamma:0 (float32_ref 512) [512, bytes: 2048]
    discriminator/d_h4_lin/Matrix:0 (float32_ref 18432x1) [18432, bytes: 73728]
    discriminator/d_h4_lin/bias:0 (float32_ref 1) [1, bytes: 4]
    Total size of variables: 10496388
    Total bytes of variables: 41985552
    checkpoint_dir : ./out/20210412.235725 - data - testdir - x96.z100.uniform_signed.y96.b1/checkpoint
    sample_dir : ./out/20210412.235725 - data - testdir - x96.z100.uniform_signed.y96.b1/samples
    image_path : ./data/testdir/plane.jpg
     [*] Reading checkpoints... ./out/20210412.235725 - data - testdir - x96.z100.uniform_signed.y96.b1/checkpoint
     [*] Failed to find a checkpoint
     [!] Load failed...
    
    opened by steven0301 0
Owner
Taehoon Kim
ex OpenAI
Taehoon Kim
Deeper DCGAN with AE stabilization

AEGeAN Deeper DCGAN with AE stabilization Parallel training of generative adversarial network as an autoencoder with dedicated losses for each stage.

Tyler Kvochick 36 Feb 17, 2022
DCGAN LSGAN WGAN-GP DRAGAN PyTorch

Recommendation Our GAN based work for facial attribute editing - AttGAN. News 8 April 2019: We re-implement these GANs by Tensorflow 2! The old versio

Zhenliang He 408 Nov 30, 2022
Minimal PyTorch implementation of Generative Latent Optimization from the paper "Optimizing the Latent Space of Generative Networks"

Minimal PyTorch implementation of Generative Latent Optimization This is a reimplementation of the paper Piotr Bojanowski, Armand Joulin, David Lopez-

Thomas Neumann 117 Nov 27, 2022
Unofficial implementation of Alias-Free Generative Adversarial Networks. (https://arxiv.org/abs/2106.12423) in PyTorch

alias-free-gan-pytorch Unofficial implementation of Alias-Free Generative Adversarial Networks. (https://arxiv.org/abs/2106.12423) This implementation

Kim Seonghyeon 502 Jan 3, 2023
Partial implementation of ODE-GAN technique from the paper Training Generative Adversarial Networks by Solving Ordinary Differential Equations

ODE GAN (Prototype) in PyTorch Partial implementation of ODE-GAN technique from the paper Training Generative Adversarial Networks by Solving Ordinary

Somshubra Majumdar 15 Feb 10, 2022
Pytorch implementation for reproducing StackGAN_v2 results in the paper StackGAN++: Realistic Image Synthesis with Stacked Generative Adversarial Networks

StackGAN-v2 StackGAN-v1: Tensorflow implementation StackGAN-v1: Pytorch implementation Inception score evaluation Pytorch implementation for reproduci

Han Zhang 809 Dec 16, 2022
PyTorch implementation of "Learning to Discover Cross-Domain Relations with Generative Adversarial Networks"

DiscoGAN in PyTorch PyTorch implementation of Learning to Discover Cross-Domain Relations with Generative Adversarial Networks. * All samples in READM

Taehoon Kim 1k Jan 4, 2023
Official implementation of "Learning to Discover Cross-Domain Relations with Generative Adversarial Networks"

DiscoGAN Official PyTorch implementation of Learning to Discover Cross-Domain Relations with Generative Adversarial Networks. Prerequisites Python 2.7

SK T-Brain 754 Dec 29, 2022
A simple PyTorch Implementation of Generative Adversarial Networks, focusing on anime face drawing.

AnimeGAN A simple PyTorch Implementation of Generative Adversarial Networks, focusing on anime face drawing. Randomly Generated Images The images are

Jie Lei 雷杰 1.2k Jan 3, 2023
Alias-Free Generative Adversarial Networks (StyleGAN3) Official PyTorch implementation

Alias-Free Generative Adversarial Networks (StyleGAN3) Official PyTorch implementation

NVIDIA Research Projects 4.8k Jan 9, 2023
Digan - Official PyTorch implementation of Generating Videos with Dynamics-aware Implicit Generative Adversarial Networks

DIGAN (ICLR 2022) Official PyTorch implementation of "Generating Videos with Dyn

Sihyun Yu 147 Dec 31, 2022
PyTorch implementation of Advantage Actor Critic (A2C), Proximal Policy Optimization (PPO), Scalable trust-region method for deep reinforcement learning using Kronecker-factored approximation (ACKTR) and Generative Adversarial Imitation Learning (GAIL).

PyTorch implementation of Advantage Actor Critic (A2C), Proximal Policy Optimization (PPO), Scalable trust-region method for deep reinforcement learning using Kronecker-factored approximation (ACKTR) and Generative Adversarial Imitation Learning (GAIL).

Ilya Kostrikov 3k Dec 31, 2022
This is the repository for the AAAI 21 paper [Contrastive and Generative Graph Convolutional Networks for Graph-based Semi-Supervised Learning].

CG3 This is the repository for the AAAI 21 paper [Contrastive and Generative Graph Convolutional Networks for Graph-based Semi-Supervised Learning]. R

null 12 Oct 28, 2022
StudioGAN is a Pytorch library providing implementations of representative Generative Adversarial Networks (GANs) for conditional/unconditional image generation.

StudioGAN is a Pytorch library providing implementations of representative Generative Adversarial Networks (GANs) for conditional/unconditional image generation.

null 3k Jan 8, 2023
[ICLR 2021, Spotlight] Large Scale Image Completion via Co-Modulated Generative Adversarial Networks

Large Scale Image Completion via Co-Modulated Generative Adversarial Networks, ICLR 2021 (Spotlight) Demo | Paper [NEW!] Time to play with our interac

Shengyu Zhao 373 Jan 2, 2023
Regularizing Generative Adversarial Networks under Limited Data (CVPR 2021)

Regularizing Generative Adversarial Networks under Limited Data [Project Page][Paper] Implementation for our GAN regularization method. The proposed r

Google 148 Nov 18, 2022
NR-GAN: Noise Robust Generative Adversarial Networks

NR-GAN: Noise Robust Generative Adversarial Networks (CVPR 2020) This repository provides PyTorch implementation for noise robust GAN (NR-GAN). NR-GAN

Takuhiro Kaneko 59 Dec 11, 2022
HiFi-GAN: Generative Adversarial Networks for Efficient and High Fidelity Speech Synthesis

HiFi-GAN: Generative Adversarial Networks for Efficient and High Fidelity Speech Synthesis Jungil Kong, Jaehyeon Kim, Jaekyoung Bae In our paper, we p

Rishikesh (ऋषिकेश) 31 Dec 8, 2022