# VITA-Group/TransGAN

[NeurIPS‘2021] "TransGAN: Two Pure Transformers Can Make One Strong GAN, and That Can Scale Up", Yifan Jiang, Shiyu Chang, Zhangyang Wang

Repository: https://github.com/VITA-Group/TransGAN
Canonical: https://ross.abutalabs.com/products/transgan
Language: Python
License: NOASSERTION
License Family: other
Topics: transformer, transformer-encoder, transformer-models, gan, pytorch
Last push: 2022-11-03T01:00:41+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 2030, "days_push": 1400, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1695, forks 203 (observed 2026-08-28T04:05:23.804062+00:00)

## What it is
Official PyTorch implementation of TransGAN, a NeurIPS 2021 paper that builds a GAN whose generator and discriminator are both pure transformers. It includes training and evaluation scripts for CIFAR and other image datasets with distributed training, FID/IS evaluation, and data augmentation.

## Use cases
- train a GAN using pure transformer architectures
- generate images with a transformer-based generator
- reproduce TransGAN results from the NeurIPS 2021 paper
- evaluate GAN sample quality with FID and IS metrics
- experiment with transformer discriminators for image synthesis
- study scaling behavior of transformer-based GANs

## When to choose
- you want to train or extend a transformer-only GAN in PyTorch
- you need a reference implementation of the TransGAN paper
- you are researching transformer architectures for image generation

## When to avoid
- you need a production-ready image generation service
- you want a well-maintained library with active support
- you need a non-research license for commercial use

## Facets
- artifact type: library
- maturity: maintenance
- function: machine-learning, deep-learning, image-processing
- domain: machine-learning, deep-learning, computer-vision, image-processing
- platform: python
- tags: gan, transformer, generative-models, pytorch, research-code, image-generation, neurips-2021, gpu, linux

## Member repositories
- VITA-Group/TransGAN (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:23.804062+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:37:55.774613+00:00, confidence not recorded.
  - readme: https://github.com/VITA-Group/TransGAN (fetched 2026-08-28T04:05:23.804062+00:00, sha 9032f97fa824)
- Data as of 2026-08-30T08:39:29.467469+00:00.
