@ericyocam6
Eric YocamDeveloper▲35
Professor, California Polytechnic State University
4d ago · New project · Agents · San Luis Obispo

Shipped: GAN-Based Handwritten Digit Generation

An open-source generative AI proof of concept demonstrating how Generative Adversarial Networks (GANs) learn to create synthetic handwritten digit images using the MNIST dataset.

The project implements two competing neural networks: a generator that produces synthetic 28×28 grayscale digit images from random noise, and a discriminator that learns to distinguish generated images from real handwritten digits.

The generator uses transposed convolutional layers, batch normalization, and LeakyReLU activations. The discriminator uses convolutional layers, dropout, and binary classification to evaluate image authenticity.

Both networks are trained through an adversarial learning process, with generated images saved periodically to visualize training progress.

The repository includes an executable notebook and example results, providing a hands-on educational demonstration of generative AI, neural network training, and synthetic image generation.

Designed for AI developers, students, researchers, and educators exploring GAN architectures and generative machine learning.

GAN-Based Handwritten Digit Generation logoGAN-Based Handwritten Digit Generation@ericyocam/gan-handwritten-digit-generation · github.com/ericyoc/gan_mnist_gen_all_digits_poc
Generative AIGANDeep LearningMachine LearningNeural NetworksImage GenerationTensorFlowKeras

Comments2

  • @ryanallis
    Ryan Allis
    Founder of AI Lounge and SaasRise, helping founders reach $100M+ exits
    4d ago

    The images you save during training are the best marketing you have here. Stitch them into a 20-second clip of random static slowly turning into readable handwritten numbers, then post it on LinkedIn and YouTube with a link to the notebook, and you'll reach teachers and students who would never click on a repo description.

  • @ericyocam
    Eric Yocam
    Agentic AI that performs cyber quantum ai activities
    3d ago

    Great suggestion, Ryan! I agree that showing the progression from random noise to recognizable handwritten digits would make the GAN training process much easier to understand, especially for students and educators. A short video could demonstrate how the generator and discriminator improve through adversarial training without requiring viewers to understand the underlying mathematics first. I like the idea of sharing it on LinkedIn and YouTube alongside the executable notebook. Appreciate the suggestion!

Log in to join the thread.