DSR-IQA

Structurally pruned Q-ReAlign Mini with a compact fixed-prompt vocabulary, five-token quality head and an additional MOS regression head. The final score is a learned fusion of token score and MOS-head score.

This release is the SRIQA-Bench-adapted student: general-IQA distillation, then SRIQA-Bench fine-tuning. It was not trained on DISRQAD MOS.

Quick start

Install matching PyTorch/torchvision, then:

pip install transformers==5.3.0 accelerate safetensors Pillow
from transformers import AutoModel

model = AutoModel.from_pretrained(
    "visualprior/DSR-IQA", trust_remote_code=True,
).to("cuda").eval()

score = model.score("image.png")
print(score)  # float in [0, 1], higher is better

scores = model.score(["first.png", "second.png"], batch_size=2)
details = model.score("image.png", return_details=True)

CPU inference is supported with .to("cpu"); it uses FP32 and can differ slightly from BF16 CUDA scores. GPU score() uses the checkpoint's configured autocast precision. Default loading keeps FP32 parameters, including fusion. For reproducibility, pin the repository commit with revision="COMMIT_SHA". trust_remote_code=True loads the custom Python files in this repository.

Supported image formats

model.score() accepts a local image path, a pathlib.Path, a PIL image, or a list of these inputs. Supported common file formats are:

Format Extensions
JPEG .jpg, .jpeg, .jpe
PNG .png
WebP .webp
BMP .bmp
TIFF .tif, .tiff
GIF .gif

Images are decoded with Pillow and converted to RGB before preprocessing. Available formats depend on the decoders in your Pillow installation; see Pillow image formats. For animated or multipage files, only the initially opened frame/page is scored. The interface scores still images, not a full animation or video.

Output

The score is normalized perceptual quality, not original-scale SRIQA MOS. Weights for excellent/good/fair/poor/bad: [1, .75, .5, .25, 0]. Optional details contain token score, direct MOS score, alpha and probabilities. Inference needs neither a reference image nor the teacher or original base weights. Files in this repository are sufficient after downloading.

Architecture

The student keeps all 12 vision blocks and the original visual tokens. It keeps 12 of the 24 language blocks, using teacher indices [2, 3, 6, 7, 10, 11, 14, 15, 18, 19, 22, 23], and restricts input embeddings to 30 original-token IDs. Exact IDs and the layer map are stored in config.json.

Both heads read the final hidden state at the end of the fixed answer stem. The token head is a bias-free 1024 -> 5 projection. The MOS head is LayerNorm -> Linear(1024, 256) -> GELU -> Dropout(0.1) -> Linear(256, 1) -> sigmoid. The final score is alpha * token_score + (1 - alpha) * mos_score, with learned alpha.

Training

Summary of Appendix C.2 of the paper:

  1. General-IQA distillation. An unpruned Q-ReAlign-mini teacher supervises visual features (every third block), corresponding language features, full-attention maps, scores and quality-token distributions. KonIQ-10K, KADID-10K and SPAQ supply MOS, ranking and interpolated ordinal targets; head consistency is also optimized. Training uses eight epochs, physical batch 2 and effective batch 8, selecting the highest validation SRCC.
  2. SR adaptation. Without the teacher, training combines 990 SRIQA-Bench images and 248 general-IQA replay images; 110 SRIQA-Bench images select the checkpoint. MOS, ranking, ordinal and consistency losses remain, with L2-SP toward the distilled checkpoint (weight 1e-4). Fine-tuning uses two epochs, physical batch 4 and effective batch 8.

Both stages use AdamW, weight decay 0.01, 5% linear warm-up and cosine decay. Language/vision/head learning rates are 2e-5/2e-6/1e-4. First-stage loss weights: MOS 1, ranking .3, ordinal .2, consistency .05, teacher score .4, teacher tokens .5, text .02, vision .01, attention .01.

The paper's additional DISRQAD adaptation in Appendix C.3 is a separate model variant and is not included in this SRIQA-Bench release.

Release information

  • Exported parameters: 340,342,466.
  • Source checkpoint epoch metadata: 2.
  • Weights: model.safetensors; training optimizer states are not included.
  • Export provenance: EXPORT_REPORT.json; score verification: VERIFICATION.json.
  • SRIQA-Bench validation is used for checkpoint selection, not independent testing.

Scope and attribution

This model estimates perceptual quality and is not a ground-truth/reference fidelity metric. A plausible SR hallucination may receive a high visual score. The backbone comes from Q-ReAlign Mini. Please retain attribution to Q-ReAlign/Q-Align, Qwen3.5 and the training datasets.

Citation

If you use this model or DISRQAD in your research, please cite the paper below. The BibTeX entry follows the DISRQAD dataset card. Project resources and updates: DISRQAD website.

@misc{kukuzei_disrqad,
  title = {DISRQAD: Diffusion Image Super-Resolution Quality
           Assessment Dataset and Benchmark},
  author = {Kukuzei, Nikita and Borisov, Artem and
            Bogatyrev, Evgeney and Abud, Khaled and
            Chistov, Egor and Vatolin, Dmitriy},
  journal = {arXiv preprint arXiv:2610.09077},
  year = {2026},
  eprint = {2610.09077},
  url = {https://arxiv.org/abs/2610.09077}
}
Downloads last month
-
Safetensors
Model size
0.3B params
Tensor type
I64
·
F32
·
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for visualprior/DSR-IQA

Finetuned
(1)
this model

Paper for visualprior/DSR-IQA