This repository contains all source code, pre-trained models related to the paper "An Empirical Study on GANs with Margin Cosine Loss and Relativistic Discriminator"

Overview

An Empirical Study on GANs with Margin Cosine Loss and Relativistic Discriminator

This is a Pytorch implementation for the paper "An Empirical Study on GANs with Margin Cosine Loss and Relativistic Discriminator".

Requirement

  • python 3.7.3
  • pytorch 1.2.0
  • tensorflow 2.0.0
  • torchtext 0.4.0
  • torchvision 0.4.0
  • mnist

Data preparation

Training

  • Run 1_train.sh to train our proposed loss function RMCosGAN along with other loss functions on four datasets.

Appendix

Network Architectures

DCGAN Architecture for CIFAR-10, MNIST and STL-10 datasets

Operation Filter Units Non Linearity Normalization
Generator G(z)
Linear 512 None None
Trans.Conv2D 256 ReLU Batch
Trans.Conv2D 128 ReLU Batch
Trans.Conv2D 64 ReLU Batch
Trans.Conv2D 3 Tanh None
Discriminator D(x)
Conv2D 64 Leaky-ReLU Spectral
Conv2D 64 Leaky-ReLU Spectral
Conv2D 128 Leaky-ReLU Spectral
Conv2D 128 Leaky-ReLU Spectral
Conv2D 256 Leaky-ReLU Spectral
Conv2D 256 Leaky-ReLU Spectral
Conv2D 512 Leaky-ReLU Spectral

DCGAN Architecture for CAT dataset

Operation Filter Units Non Linearity Normalization
Generator G(z)
Trans.Conv2D 1024 ReLU Batch
Trans.Conv2D 512 ReLU Batch
Trans.Conv2D 256 ReLU Batch
Trans.Conv2D 128 ReLU Batch
Trans.Conv2D 3 Tanh None
Discriminator D(x)
Conv2D 128 Leaky-ReLU Spectral
Conv2D 256 Leaky-ReLU Spectral
Conv2D 512 Leaky-ReLU Spectral
Conv2D 1024 Leaky-ReLU Spectral

Experimental results

60 randomly-generated images with RMCosGAN at FID=31.34 trained on CIFAR-10 dataset

60 randomly-generated images with RMCosGAN at FID=13.17 trained on MNIST dataset

60 randomly-generated images with RMCosGAN FID=52.16 trained on STL-10 dataset

60 randomly-generated images with RMCosGAN at FID=9.48 trained on CAT dataset

Citation

Please cite our paper if RMCosGAN is used:

@article{RMCosGAN,
  title={An Empirical Study on GANs with Margin Cosine Loss and Relativistic Discriminator},
  author={Cuong Nguyen, Tien-Dung Cao, Tram Truong-Huu, Binh T.Nguyen},
  journal={},
  year={}
}

If this implementation is useful, please cite or acknowledge this repository on your work.

Contact

Cuong Nguyen ([email protected]),

Tien-Dung Cao ([email protected]),

Tram Truong-Huu ([email protected]),

Binh T.Nguyen ([email protected])

Owner
Cuong Nguyen
AI/DL researcher
Cuong Nguyen
TaCL: Improving BERT Pre-training with Token-aware Contrastive Learning

TaCL: Improving BERT Pre-training with Token-aware Contrastive Learning Authors: Yixuan Su, Fangyu Liu, Zaiqiao Meng, Lei Shu, Ehsan Shareghi, and Nig

Yixuan Su 79 Nov 04, 2022
An implementation on "Curved-Voxel Clustering for Accurate Segmentation of 3D LiDAR Point Clouds with Real-Time Performance"

Lidar-Segementation An implementation on "Curved-Voxel Clustering for Accurate Segmentation of 3D LiDAR Point Clouds with Real-Time Performance" from

Wangxu1996 135 Jan 06, 2023
Grow Function: Generate 3D Stacked Bifurcating Double Deep Cellular Automata based organisms which differentiate using a Genetic Algorithm...

Grow Function: A 3D Stacked Bifurcating Double Deep Cellular Automata which differentiates using a Genetic Algorithm... TLDR;High Def Trees that you can mint as NFTs on Solana

Nathaniel Gibson 4 Oct 08, 2022
PyTorch implementation of "LayoutTransformer: Layout Generation and Completion with Self-attention"

PyTorch implementation of "LayoutTransformer: Layout Generation and Completion with Self-attention" to appear in ICCV 2021

Kamal Gupta 75 Dec 23, 2022
PyTorch implementation of saliency map-aided GAN for Auto-demosaic+denosing

Saiency Map-aided GAN for RAW2RGB Mapping The PyTorch implementations and guideline for Saiency Map-aided GAN for RAW2RGB Mapping. 1 Implementations B

Yuzhi ZHAO 20 Oct 24, 2022
Code of PVTv2 is released! PVTv2 largely improves PVTv1 and works better than Swin Transformer with ImageNet-1K pre-training.

Updates (2020/06/21) Code of PVTv2 is released! PVTv2 largely improves PVTv1 and works better than Swin Transformer with ImageNet-1K pre-training. Pyr

1.3k Jan 04, 2023
Repo for "Event-Stream Representation for Human Gaits Identification Using Deep Neural Networks"

Summary This is the code for the paper Event-Stream Representation for Human Gaits Identification Using Deep Neural Networks by Yanxiang Wang, Xian Zh

zhangxian 54 Jan 03, 2023
PyTorch implementation of Anomaly Transformer: Time Series Anomaly Detection with Association Discrepancy

Anomaly Transformer in PyTorch This is an implementation of Anomaly Transformer: Time Series Anomaly Detection with Association Discrepancy. This pape

spencerbraun 160 Dec 19, 2022
A Python library created to assist programmers with complex mathematical functions

libmaths libmaths was created not only as a learning experience for me, but as a way to make mathematical models in seconds for Python users using mat

Simple 73 Oct 02, 2022
Python Implementation of algorithms in Graph Mining, e.g., Recommendation, Collaborative Filtering, Community Detection, Spectral Clustering, Modularity Maximization, co-authorship networks.

Graph Mining Author: Jiayi Chen Time: April 2021 Implemented Algorithms: Network: Scrabing Data, Network Construbtion and Network Measurement (e.g., P

Jiayi Chen 3 Mar 03, 2022
Generating images from caption and vice versa via CLIP-Guided Generative Latent Space Search

CLIP-GLaSS Repository for the paper Generating images from caption and vice versa via CLIP-Guided Generative Latent Space Search An in-browser demo is

Federico Galatolo 172 Dec 22, 2022
SIMULEVAL A General Evaluation Toolkit for Simultaneous Translation

SimulEval SimulEval is a general evaluation framework for simultaneous translation on text and speech. Requirement python = 3.7.0 Installation git cl

Facebook Research 48 Dec 28, 2022
The official re-implementation of the Neurips 2021 paper, "Targeted Neural Dynamical Modeling".

Targeted Neural Dynamical Modeling Note: This is a re-implementation (in Tensorflow2) of the original TNDM model. We do not plan to further update the

6 Oct 05, 2022
Evolving neural network parameters in JAX.

Evolving Neural Networks in JAX This repository holds code displaying techniques for applying evolutionary network training strategies in JAX. Each sc

Trevor Thackston 6 Feb 12, 2022
Einshape: DSL-based reshaping library for JAX and other frameworks.

Einshape: DSL-based reshaping library for JAX and other frameworks. The jnp.einsum op provides a DSL-based unified interface to matmul and tensordot o

DeepMind 62 Nov 30, 2022
This is the repository for the paper "Have I done enough planning or should I plan more?"

Metacognitive Learning Tool box https://re.is.mpg.de What Is This? This repository contains two modules used to analyse metacognitive learning in huma

0 Dec 01, 2021
PAMI stands for PAttern MIning. It constitutes several pattern mining algorithms to discover interesting patterns in transactional/temporal/spatiotemporal databases

Introduction PAMI stands for PAttern MIning. It constitutes several pattern mining algorithms to discover interesting patterns in transactional/tempor

RAGE UDAY KIRAN 43 Jan 08, 2023
LaneAF: Robust Multi-Lane Detection with Affinity Fields

LaneAF: Robust Multi-Lane Detection with Affinity Fields This repository contains Pytorch code for training and testing LaneAF lane detection models i

155 Dec 17, 2022
Chainer Implementation of Semantic Segmentation using Adversarial Networks

Semantic Segmentation using Adversarial Networks Requirements Chainer (1.23.0) Differences Use of FCN-VGG16 instead of Dilated8 as Segmentor. Caution

Taiki Oyama 99 Jun 28, 2022
Official PyTorch implementation of Data-free Knowledge Distillation for Object Detection, WACV 2021.

Introduction This repository is the official PyTorch implementation of Data-free Knowledge Distillation for Object Detection, WACV 2021. Data-free Kno

NVIDIA Research Projects 50 Jan 05, 2023