DEV Community

Cover image for They demanded a picture
Aryan Garg
Aryan Garg

Posted on AI-assisted

They demanded a picture

Hacktoberfest Weekend Challenge: Build for a Friend Submission 🤝

This is a submission for the Hacktoberfest Weekend Challenge: Build for a Friend

What I Built

We built a local upscaler! My friends love looking at pictures. But as the screens increase in resolution, the picture starts...fading away. Imagine that, a digital album fading away like an old picturebook. particularly the faces, which become really blurry.

Upscaling is a popular technology, using AI to recreate the edges and lines to make the image sharper. Most existing tools require the customer to send images over to a random website, something my friends didn't want to do with their photogaphs.

drumroll....ENTER LOCAL LLMS

Demo

Code

Revive

Revive makes old family photos sharper, gently fixes blurry faces, and writes a short caption for each one When it's done, you get a little photo album you can open on any computer, even without internet.

Your photos stay on this computer. Nothing is uploaded anywhere. After the one-time setup, Revive works with the internet switched off.

The Revive start page

Setting it up (once)

You need two free programs first:

  1. Python: download it from python.org/downloads and install it. On Windows, tick the box that says "Add python.exe to PATH" on the first screen of the installer.
  2. Ollama: download it from ollama.com/download and install it. This is what lets Revive write captions on your own computer.

Then set up Revive itself:

  • Windows: open the scripts folder and double-click setup.bat.
  • Mac: open the scripts folder and double-click Setup Revive.command. If your Mac says it can't be opened, right-click it, choose…

How I Built It

Revive is a fast API server with a simple HTML/CSS/JS landing page. It literally has no build steps, less to break on other systems.
This is specialised for faces, which is the most we could do in the 24 hours we had.

Processing order

GFPGAN v1.4 at original size --> Real-ESRGAN(2x) --> gemma4(via ollama)

This doesn't need a GPU either! so any laptop device can use this program to revive their photos on the fly :D

We focused on intuitivity, using established typography rules, and easy to undestand exit codes and error messages, this software can be used by anyone

Faces that look like themselves

Meticulous testing was done to make the faces look as close as possible to the orignal, tinkering with GFPGAN's weight values to avoid airbrushing and glassing was an excercise in endurance.

Offline

The primary requirement, everyone was against sending data out, so we brought the software in.

Why Does Open Innovation Matter?

Open models were the only way to build what they wanted.

Nothing leaves the computer

Its offline, there isn't even any bit of code that sends anything online

Works anytime

No internet, no condition, no firewalls, just your photos and the tool

Customizable!!

We made it, we can change it. Open source ftw

Prize Categories

Best use of gemma - Gemma4-e4b runs locally and is the brain here, it writes captions and makes the albums.

Did they like it??

YES!!!

We got some great reactions

Built by

herbs_and_spices_api
satvik_shashank
dhriti_gupta

Top comments (0)