← all repositories
RaphaelMeudec/deblur-gan

Deblurring photos with the brute force of adversarial spite

A Keras port of DeblurGAN that learns to undo motion blur by pitting two neural networks against each other until one gives up and produces sharp images.

600 stars Python Image · Video · Audio
deblur-gan
Velocity · 7d
+0.2
★ / day
Trend
steady
star history

What it does

This is a straightforward Keras reimplementation of the 2017 DeblurGAN paper. It takes motion-blurred photographs and attempts to reconstruct the sharp original using a conditional GAN setup: a generator network proposes deblurred versions, while a discriminator tries to tell them apart from real sharp images. The repo includes scripts for training on the GOPRO dataset, testing, and deblurring your own images with a saved generator model.

The interesting bit

The adversarial setup is the hook. Rather than training a single network with a pixel-perfect loss function—which tends to produce blurry averages—the discriminator forces the generator to produce outputs that are structurally plausible enough to fool a second network. It’s expensive, unstable, and occasionally magical.

Key highlights

  • Clean Keras implementation of the full DeblurGAN pipeline (generator + discriminator)
  • Ready-to-use scripts for training, testing, and one-off image deblurring
  • Works with the standard GOPRO motion blur dataset; includes data organization helper
  • Medium tutorial linked for the “how does this actually work” crowd
  • Sample results shown in-repo: sharp → blurred → deblurred triptych

Caveats

  • README is minimal; no pretrained weights provided, so you’re training from scratch or sourcing your own
  • Paper is from 2017; newer deblurring methods (notably diffusion-based and more efficient GAN variants) have since advanced the state of the art
  • GOPRO dataset is a chunky Google Drive download; no automatic fetch script

Verdict

Worth a look if you’re teaching or studying GAN architectures, or need a hackable Keras baseline for motion deblurring. Skip it if you want production-ready deblurring out of the box—this is a research reproduction, not a product.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.