Spaces:
Running on Zero
Download README.md from shreshthsaini/JLD-demo: direct link, hf CLI and curl.
- Browser
- Download file 2.85 kB
-
https://huggingface.co/spaces/shreshthsaini/JLD-demo/resolve/main/README.md
- Command line
-
hf download hf://spaces/shreshthsaini/JLD-demo/README.md
-
curl -L -o README.md https://huggingface.co/spaces/shreshthsaini/JLD-demo/resolve/main/README.md
A newer version of the Gradio SDK is available: 6.30.0
title: JLD Perceptual Distance
emoji: 🔍
colorFrom: blue
colorTo: yellow
sdk: gradio
sdk_version: 6.29.1
python_version: '3.12'
app_file: app.py
pinned: false
license: mit
tags:
- image-quality-assessment
- perceptual-distance
- full-reference
- dinov2
- arxiv:2610.05967
An author-maintained interactive demo of JLD: Perceptual Distance Through a Jacobian Lens.
Paper · Code · Research website
Upload an aligned reference/distorted pair, select JLD or JLD-fast, and obtain a scalar distance plus a local lens response overlay. Lower means more similar. The overlay excludes the global CLS term and is normalized separately for each pair.
Both images must be aligned and have the same size. Uploads may be up to 24 megapixels, 8192 pixels on the longest side, and 10 MB each. By default, large pairs are reduced together with the same Lanczos filter to fit the hosted scoring limit of 262,144 pixels and a longest side of 1024 pixels. The result reports the original, resized, and scored dimensions. This score is for the resized pair. Disable Resize large pairs for this demo to require native resolution; large pairs then receive an explanatory error. Small pairs keep their native pixels. RGB conversion and a center crop to multiples of 14 pixels follow the official scorer. Use the local package for native-resolution scoring of larger images. The pretrained encoder loads on hosted startup, while the fitted lens is included in the package. The hosted Space uses free shared ZeroGPU access; queueing and daily usage limits may apply.
Local use with uv
uv add "jacobian-lens-distance @ https://github.com/shreshthsaini/jld/releases/download/v1.1.0/jacobian_lens_distance-1.1.0-py3-none-any.whl"
from jld import JLD
metric = JLD.pretrained("full")
distance = metric("reference.png", "distorted.png")
To run this Space checkout locally:
uv run --python 3.12 --with-requirements requirements.txt app.py
The app runs on CPU and listens on localhost for local runs. Hugging Face manages external access and dynamic GPU allocation when deployed as a ZeroGPU Space.
Citation
@article{saini2026jld,
title={JLD: Perceptual Distance Through A Jacobian Lens},
author={Saini, Shreshth and Adsumilli, Balu and Bovik, Alan C.},
journal={arXiv preprint arXiv:2610.05967},
year={2026}
}
Code is MIT licensed. Bundled images have their own provenance and source reuse statement in examples/PROVENANCE.md. Encoder weights retain their upstream license. No uploaded images or scores are deliberately archived by the app; Gradio and Hugging Face may keep temporary upload files under their platform policies.