All models

erik_sgan

The generator half of Odena's semi-supervised GAN, traced from the PyTorch-GAN collection.

Diffusion and generative · 13 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (18 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
1.1M
Operations
13
Framework
PyTorch
Recurrent
No
Published
2016
Cited by
894 (as of 23 November 2026)
Authors
Augustus Odena
License
MIT
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m4685
Graph hash
95d9a2d2868bceea4de98873cc2af5bef6f183700be16f1d40ca27d57980164c
Skeleton hash
1c096f818ff50d948050c050ec2ef79d717fb15bef8a88332532db3f7afb3948
Architecture hash
a272765c51a959d85e7faafad35a0ba3acd5702e518c0f8764e8bf3320f77cf1
Diagram SHA-256
3c87e77eb527d600ed321c7f426139975dff132262070054506e4d7da196524a
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

SGAN extends the GAN so that the discriminator doubles as a classifier, predicting which of N+1 classes an input belongs to, where the extra class stands for generated samples. The claim is twofold: a more data-efficient classifier, and higher quality samples than a regular GAN. The change itself is small, since the usual single sigmoid unit becomes a softmax output layer with one unit per class.

The experiments ran on MNIST with an architecture similar to that in Radford et al. (2015), training once with the real labels and once with only REAL and FAKE. The SGAN outputs were significantly more clear than the GAN outputs. Classification gains grew as the training set shrank, which the author reads as the shared weights of D and C improving data-efficiency. The captured member comes from the PyTorch-GAN collection, whose author warns that its architectures will not always mirror the ones proposed in the papers.

Key idea. Giving the GAN discriminator N+1 softmax outputs so that one network learns a generative model and a classifier simultaneously.

  • SGAN
  • semi-supervised GAN
  • Semi-Supervised Learning with Generative Adversarial Networks
  • Odena
  • N+1 classes
  • GAN
  • MNIST
  • PyTorch-GAN

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@misc{odena2016semisupervisedlearninggenerativeadversarial,
      title={Semi-Supervised Learning with Generative Adversarial Networks}, 
      author={Augustus Odena},
      year={2016},
      eprint={1606.01583},
      archivePrefix={arXiv},
      primaryClass={stat.ML},
      url={https://arxiv.org/abs/1606.01583}, 
}