Urgent.News

What's breaking now, across thousands of outlets.

AI

Upscaling guest photos with a local model instead of an API

I run Knipsmig , a QR-code photo sharing service for weddings and parties. Guests scan a code and upload straight from the phone, no app. Most of those uploads are 12 MP and print fine. A meaningful slice are not: photobooth captures at 1080x810, WhatsApp forwards at 1600x1200, screenshots, old scans someone re-uploaded. Those end up in the printed photo book looking soft. So I added an "Improve…

Knipsmig is a QR-code photo sharing service for weddings and parties where guests upload photos directly from their phones using a QR code. Many of these uploads are not of high quality, such as photobooth captures, WhatsApp forwards, and screenshots. To address this, Knipsmig added an "Improve resolution" option to their editor that upscales the images by up to 4x the pixels.

This feature runs entirely on the Knipsmig server without the need for an API or vendor. The developer chose to implement this feature instead of using a generative model like Gemini or OpenAI due to concerns about regenerating the images and altering the faces of the guests. Additionally, running the upscaling locally eliminates the need for a Data Processing Agreement for a third-party service and saves on costs.

The upscaling model used is realesr-general-x4v3 from the Real-ESRGAN project, which is faster and more cost-effective than a full RRDBNet x4plus model. To optimize the performance, the developer tiled the images and ran them through the model in chunks, avoiding the need for large Ruby arrays. The feature is limited to photos with a longest edge at or below 2048 pixels, and the UI provides a preview of the upscaled image before the user commits the changes.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in AI

How Figma Uses AI Agents for Security

The engineering team at software company Figma recently documented how they built AI agents to help their security team investigate alerts, search past incidents, check company systems, and even…

More from Sunday 6 September →