Downloads · 30 days
7
13% of all-time downloads
olaverse/prism-denoiser
prism-denoiser is a image-to-image model from olaverse. Use it when you need one image transformed into another. The card lists the license as apache-2.0.
Downloads · 30 days
7
13% of all-time downloads
All-time downloads
54
Public
Repo size
17.4 MB
Likes
0
Public
Click a slice to open those files.
.pt17.4 MB · 100%
From the Hugging Face model README

prism models
prism-denoiser removes real-world image degradation — Gaussian noise, blur, and JPEG-like compression artifacts — using a compact U-Net trained with on-the-fly random degradation. Unlike the fixed-scale upscalers, this model doesn't change resolution: it takes a degraded image and returns a cleaner version at the same size, useful as a standalone restoration tool or as pre-processing before other image tasks.
Production-usable as a "meaningfully better than doing nothing" restoration step — reliably reduces noise and recovers accurate color, though on complex, high-detail scenes some residual grain typically remains rather than a fully clean result. See Benchmarks and Known Limitations for the honest picture.
| Architecture | Compact U-Net (3 down/up levels, base width 48) |
| Input / Output | RGB image, 128x128, same resolution in and out |
| Training data | PD12M, pxhere, cc0-textures, ambientcg (Apache/CC0-licensed) |
| Training | Mixed precision, on-the-fly random degradation (blur + Gaussian noise + JPEG-approximation, each applied with independent random probability/severity per sample), L1 + VGG-perceptual loss, early stopping on validation PSNR |
from huggingface_hub import hf_hub_download
import torch, importlib.util, json
from PIL import Image
import torchvision.transforms.functional as TF
model_file = hf_hub_download(repo_id="olaverse/prism-denoiser", filename="model.py")
ckpt_file = hf_hub_download(repo_id="olaverse/prism-denoiser", filename="pytorch_model.pt")
config_file = hf_hub_download(repo_id="olaverse/prism-denoiser", filename="config.json")
spec = importlib.util.spec_from_file_location("model", model_file)
model_module = importlib.util.module_from_spec(spec)
spec.loader.exec_module(model_module)
config = json.load(open(config_file))
model = model_module.UNet(**config)
model.load_state_dict(torch.load(ckpt_file, map_location="cpu")["net"])
model.eval()
img = Image.open("noisy.jpg").convert("RGB").resize((128, 128))
x = TF.to_tensor(img).unsqueeze(0)
with torch.no_grad():
output = model(x).clamp(0, 1)
TF.to_pil_image(output[0]).save("denoised.jpg")
Trained and tested at 128x128 — resize input accordingly for best results.
Visual and PSNR comparison on two test cases (informal single-image checks, not a scored benchmark against a standard dataset):
Trained on PD12M (Spawning/PD12M, CDLA-Permissive-2.0), pxhere (nyuuzyou/pxhere, CC0), cc0-textures (nyuuzyou/cc0-textures, CC0), and ambientcg (nyuuzyou/ambientcg, CC0). Released under Apache-2.0.
@misc{prism-denoiser,
title = {prism-denoiser},
author = {Olaverse},
year = {2026},
url = {https://huggingface.co/olaverse/prism-denoiser}
}