• Stars
    star
    182
  • Rank 211,154 (Top 5 %)
  • Language
    Python
  • Created about 5 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Seeing what a GAN cannot generate. Visualizes and quantifies object classes within scenes that are outside the range of a GAN.

Seeing What a GAN Cannot Generate

State-of-the art GANs can create increasingly realistic images, yet they are not perfect.

What is a GAN unable to generate? This repository contains the code for the ICCV 2019 paper Seeing What a GAN Cannot Generate, which introduces a framework that can be used to answer this question.

GAN reconstruction Real photo

Our goal is not to benchmark how far the generated distribution is from the target. Instead, we want to visualize and understand what is different between real and fake images.

Mode-dropping and the problem of visualizing omissions

We visualize the omissions of an image generator in two ways.

  1. We identify omissions within the distribution of images.
  2. We identify omissions within individual images.

Seeing omissions in the distribution

To understand omissions in a GAN's output distribution, we compare segmentation statistics between the GAN output and the training distribution.

A Progressive GAN trained to generate LSUN outdoor church images is analyzed below.

The model does not generate enough pixels of people, cars, fences, palm trees, or signboards compared to the training distribution. The script run_fsd.sh and the notebook seeing_distributions.ipynb show how we collect and visualize these segmentation statistics.

Seeing omissions in individual images

To understand omission in specific GAN-generated output, we must pair the output with a real photo that shows what the GAN should have drawn but did not. So we compare real training photos to a reconstructed image derived from the model of the GAN.

These visualizations are created by run_invert.sh.

People

As seen in the distribution statistics, thie GAN does not draw enough people. By visualizing reconstructions, we can see how: the GAN seems to avoid drawing large person figures entirely, instead synthesizing plausible scenes without people.

GAN reconstruction Real photo

Vehicles

A similar effect is seen for vehicles.

GAN reconstruction Real photo

Signs

GAN reconstruction Real photo

Monuments

GAN reconstruction Real photo

Palm trees

GAN reconstruction Real photo

More Repositories

1

seedrandom

seeded random number generator for Javascript
JavaScript
1,955
star
2

rewriting

Rewriting a Deep Generative Model, ECCV 2020 (oral). Interactive tool to directly edit the rules of a GAN to synthesize scenes with objects added, removed, or altered. Change StyleGANv2 to make extravagant eyebrows, or horses wearing hats.
Python
537
star
3

how-to-read-pytorch

Quick, visual, principled introduction to pytorch code through five colab notebooks.
Jupyter Notebook
316
star
4

dissect

Code for the Proceedings of the National Academy of Sciences 2020 article, "Understanding the Role of Individual Units in a Deep Neural Network"
Python
300
star
5

baukit

Python
37
star
6

covid-19-chart

Chart of current COVID-19 time series data. Enables a variety of county- state- and nation-level comparisons and data exploration.
HTML
18
star
7

see

see.js interactive eval panel that allows debugging of nested javascript scope.
JavaScript
16
star
8

sidn-handbook

The Structure and Interpretation of Deep Networks Handbook
Jupyter Notebook
12
star
9

xsrand

Several fast 32-bit xor-shift random number generators implemented in Javascript.
JavaScript
12
star
10

conformal

An interactive HTML conformal map viewer.
HTML
7
star
11

gpwidget

Jupyter Notebook
7
star
12

envs

Conda environments for pytorch-oriented deep learning work.
Shell
5
star
13

quick-netdissect

Lightweight reimplementation of netdissect for pytorch (under development)
Python
4
star
14

webcrush

A utility for minifying and LZW compressing an HTML file.
JavaScript
4
star
15

colabsecrets

A repo for keeping track of colab tricks.
Python
4
star
16

splaylist

Splay tree in Javascript, with fast indexing and order statistics. Better than a linked list.
JavaScript
4
star
17

make-full-linux-history

Yoann Padioleau's scripts to graft together a nearly complete history of linux commits as a git repo.
OCaml
3
star
18

miniplaces

baseline setup for alexnet on miniplaces using pytorch
Python
2
star
19

mandelbrot

Updated code for http://davidbau.com/mandelbrot/, an early HTML5 demo of the canvas element. See http://davidbau.com/archives/2009/09/27/mandelbrot.html
HTML
2
star
20

ganclass

Python
1
star
21

heidisudoku

JavaScript
1
star
22

panoptic-segmentation

Python
1
star
23

thisxsite

"This X does not exist" website
Python
1
star
24

pytorch-setup

Just to share a conda setup that I use
Shell
1
star
25

glowjs

A package containing the glowscript javascript libaries as a single javascript file.
JavaScript
1
star
26

sudokui

A simplified sudoku UI for experimenting with A/B testing: MIT 6.831
JavaScript
1
star
27

net-intent

Simple experiment to explore a jacobian method for determining hidden unit intent.
Python
1
star