OpenViSTAI · Agents · Blockchain · Crypto
Menu
AI Models

Improvedgan Pytorch

A Python/PyTorch implementation of a semi-supervised generative adversarial network for MNIST, with a command-line training script and a supplied trained model.

Independent OpenViST project profile, based on linked sources.

Improvedgan Pytorch — MNIST experiments with limited labeled examples and additional unlabeled data
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use it when you want a focused code example for semi-supervised GAN training on MNIST, rather than a hosted model service or a general-purpose image-generation tool.

Who it is for

  • Researchers and learners exploring semi-supervised image classification with MNIST.
  • PyTorch users studying feature matching and GAN implementation choices.

Documented uses

  • Train an MNIST model using a small labeled set alongside unlabeled examples.
  • Study how feature matching and generated samples relate to class separation.
  • Inspect a GAN implementation that includes a supplied trained model and documented CPU or CUDA execution.
Before you choose

Requirements & limits

The repository is public and identified as open source. Its README documents command-line use; Python 3.7, PyTorch 1.2, tensorboardX and torchvision are specified.

  • The documented dataset and example configuration are specific to MNIST.
  • The README's default configuration uses CPU, with a documented --cuda option for GPU execution.
  • The maintainer reports changing the generator's final layer to Softplus after encountering reproduction difficulties and exploding gradients.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Run the MNIST implementation

Start the repository's documented training script with its default CPU configuration or CUDA option.

Before you start

  • Python 3.7
  • PyTorch 1.2, tensorboardX and torchvision
  • The repository files, including ImprovedGAN.py

Steps

  1. Install the documented Python dependencies.

  2. Run the command below for the default CPU configuration.

    Documented command
    python ImprovedGAN.py
  3. Use the command below to select GPU execution.

    Documented command
    python ImprovedGAN.py --cuda

Expected outcome

The script runs the MNIST semi-supervised GAN configuration; the README says default settings include saving, autoloading and TensorBoard-format log generation.

Guide limitations

  • The README's reported 98.5% test accuracy is tied to its stated setup of 100 labeled and 59,000 unlabeled examples after 100 epochs, and is not a general performance guarantee.
  • The README does not give additional GPU setup instructions.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
20 November 2026
Original website title
Sleepychord/ImprovedGAN-pytorch · Official homepage title · retained in its source language