RestoRect: Degraded Image Restoration via Latent Rectified Flow & Feature Distillation
Listen
Radio episode about this paper
Transcript
Introduction to the show: ident: AI Radio. Generated commentary on the latest Artificial Intelligence papers.
Tom: We're looking at the paper: "RestoRect: Degraded Image Restoration via Latent Rectified Flow & Feature Distillation".
Jane: Here's the gist of the paper. The gist: RestoRect proposes a novel Latent Rectified Flow Feature Distillation method for restoring degraded images by reformulating knowledge distillation as a generative process through latent rectified flow.
Jane: The framework combines Retinex decomposition with learnable anisotropic diffusion constraints and trigonometric color space polarization to eliminate artifacts and boost restoration quality.
Paper summary: Jane: So, we’ve looked at how they did it in "RestoRect: Degraded Image Restoration via Latent Rectified Flow and Feature Distillation," and now we need to talk about what this paper actually is called and what it means for the field.
Tom: It basically takes those big transformer models that are way too slow for real-time use and teaches a smaller student model how to do the same thing really fast, by using this new flow matching idea.
Lu: The core idea is that instead of just copying pixel values or static features, the student learns a path in some latent space. This path connects pure noise to the target restored image features.
Meng: So, what does that mean for deployment? If we can distill those complex teacher models into something faster, it could actually change how quickly we can process images at scale.
Lalam: I’m looking at the results on LOL-v2 and LSUI, where they beat a baseline by one point seven six decibels in PSNR for low-light tasks; that's concrete performance data right there.
Tom: Concrete is good, Lalam, but what about the limitations? Is this flow matching stuff going to be too heavy when we put it into production pipelines?
Jane: Well, the authors mention they used a two-stage training process and some auxiliary constraints like anisotropic diffusion and color space polarization; that’s how they keep things stable during the distillation phase.
Lu: The whole point of using rectified flow is to turn feature distillation into a generative process where we are learning trajectories, which is more dynamic than just matching fixed points between the teacher and student features.
Meng: And from an engineering standpoint, if the training is more stable, that means less time debugging the student network during fine-tuning. That’s a real win for production teams.
Lalam: I'm confident in what they show on those fifteen datasets covering low-light, underwater, and fundus enhancement tasks; they showed solid gains across the board.
Tom: It sounds like this method is really about making the knowledge transfer smarter, not just faster. Where does this leave us when we think about building systems that need to restore images quickly?
Conclusion: Jane: So we’re wrapping up this look at "RestoRect: Degraded Image Restoration via Latent Rectified Flow and Feature Distillation."
Tom: Basically, this paper tackles that slow versus fast problem in image restoration by using a new flow matching idea to transfer knowledge from big teacher models to smaller student ones.
Lu: The core concept is that instead of just copying static features, the student learns a dynamic path in latent space connecting noise to the target image features.
Meng: This could mean we can actually run high-quality restoration on devices with less power than we thought possible because the model gets much lighter and faster.
Lalam: The paper shows solid gains across fifteen datasets covering low-light, underwater, and fundus enhancement tasks.
Tom: So this method makes the knowledge transfer smarter by modeling it as a generative process instead of just a static feature match. Where does this leave us when we think about building systems that need to restore images quickly?
Shourya Verma, Mengbo Wang, Ananth Grama, Nadia Atallah Lanman
Department of Computer Science, Purdue University, USA
cs.CV
Submitted: 2025-09-27
Updated: 2026-10-18
Code: https://github.com/shouryaverma/RestoRect
License: http://creativecommons.org/licenses/by-nc-sa/4.0/
Importance score: 89/100
The gist: The gist: RestoRect proposes a novel Latent Rectified Flow Feature Distillation method for restoring degraded images by reformulating knowledge distillation as a generative process through latent
Key concepts
- Latent Rectified Flow
- This is a generative process where the student network learns to create teacher-quality features by moving along specific paths (trajectories) in a compressed, lower-dimensional latent space. Instead of just matching static features, the flow allows the student to synthesize complex features dynamically based on learned velocity predictions.
- Feature Layer Extraction (FLEX) Loss
- This loss function ensures robust knowledge transfer between different network architectures. It works by cross-normalizing the teacher and student features using statistics derived from the student network itself, combined with percentile-based outlier detection to align their feature distributions effectively.
- Anisotropic Diffusion Constraint
- This constraint enforces structural consistency in the restored image. It uses a mathematical operator that calculates how much an image structure should change based on its gradients, allowing the model to maintain sharp details and correct artifacts during the restoration process.
- Trigonometric Color Space Polarization
- This technique is used to handle color discontinuities, particularly red ones. By transforming the image into a polarized color space using trigonometric parameters, the model can better distinguish between different color components and eliminate unnatural red streaks in the final output.
Terminology
Summary
The gist: RestoRect proposes a novel Latent Rectified Flow Feature Distillation method for restoring degraded images by reformulating knowledge distillation as a generative process through latent rectified flow.
How it works
-
The framework combines Retinex decomposition with learnable anisotropic diffusion constraints and trigonometric color space polarization to eliminate artifacts and boost restoration quality.
-
The student networks learn dynamic feature synthesis via flow matching dynamics using linear interpolation trajectories between noise and target features in latent space.
-
The core Feature Layer Extraction (FLEX) Loss addresses distribution mismatch by normalizing teacher and student features using student statistics.
-
The framework employs a two-stage training process: Stage 1 trains the teacher with pixel and perceptual losses to achieve high-quality restoration, while Stage 2 distills knowledge via latent rectified flow in two phases.
Teacher Network Pre-training
The teacher network utilizes well-established Retinex theory to derive illumination-informed features as priors for knowledge distillation.
This involves using two decomposition networks, Dl (low-light) and Dh (normal-light), each mapping D(I) → (R, L) with R ∈ R H×W×3 and L ∈ R H×W×1.
The teacher network uses a UNet transformer architecture with key innovations for robust image restoration.
Key architectural innovations include Spatial Channel Layer Normalization (SCLN) and Query-Key normalization to ensure attention stability under degraded inputs.
The Retinex attention mechanism uses separate conditioning for reflectance and illumination components, allowing queries from reflectance components to attend to illumination structure.
Student Network with Latent Rectified Flow
The student network is trained using a rectified flow formulation where the interpolation path is defined as xt = (1 − t)z + tfteach, t ∈ [0, 1].
Velocity prediction networks are trained to predict this velocity field using a Residual MLP architecture.
The training protocol involves two phases: Phase 1 trains the rectified flow components while freezing the main restoration network to establish stable velocity prediction capabilities.
Phase 2 trains the full restoration network using features generated by learned velocity predictors where Lphase2 = Lrec + λF LEXLF LEX + λvel(Lrex vel + Limg vel).
Auxiliary Constraints and Loss Functions
The framework incorporates several auxiliary constraints to enforce structural consistency and eliminate artifacts.
These include the Anisotropic Diffusion operator, which computes A(I) = ∇ · (c(∇I)∇I) with a learnable sensitivity parameter s.
The Texture Consistency Loss enforces structural similarity between input and predicted reflectance: Ltex = ∥A(Iinput) − A(Rpred)∥1.
The Polarized HVI Color Space is introduced to eliminate red discontinuity through trigonometric parameterization.
The Polarized Color Loss is computed as Lcol = ∥H pred polar − H gt polar∥1 + ∥V pred polar − V gt polar∥1 + ∥I pred polar − I gt polar∥1.
The complete teacher training objective combines these losses: Lteach = Lrec + Lvgg + Lsty + λtexLtex + λcolLcol + λlumLlum.
Performance and Evaluation
RestoRect achieves state-of-the-art performance across 15 datasets covering low-light, underwater, backlit, and fundus enhancement.
For the low-light image enhancement (LLIE) task on LOL-v2 Real and LSUI, RestoRect outperforms RetiDiff by 1.76dB PSNR on UIEB.
In the backlighting image enhancement (BAID) task, RestoRect demonstrates substantial improvements with 4.48dB PSNR gain over RetiDiff.
The model achieves superior BIQI score of 6.033 for the real-world fundus image enhancement (FIE) task.
The student model ablation study shows that the complete FLEX formulation with Resolution Weighting (RW) achieves optimal performance on LOLv1.
Improvements for AI systems
-
Knowledge transfer between transformer architectures is improved by modeling feature distillation as a generative process using latent rectified flow, allowing students to
learn dynamic feature synthesis via flow matching dynamics using linear interpolation trajectories between noise and target features in latent space.
This enables faster convergence and inference while preserving quality across different network architectures. -
Feature alignment for multi-scale representations is enhanced through the Feature Layer Extraction (FLEX) Loss, which
normalizes both teacher and student features using student statistics
to address distribution mismatch. This cross-normalization ensuresmeaningful comparison across architecture capacity differences
by aligning features to the student's distribution while using percentile-based outlier detection for robustness. -
Image restoration speed is significantly increased by replacing iterative denoising with rectified flow ODE integration, which allows the system to solve the ODE using Euler’s method with
adaptive step sizing: xt+∆t = xt + ∆t · ϵθ(xt, t, c)
requiring only1-4 integration steps compared to 10+ steps for DDIM models.
-
Artifact reduction and structural consistency are boosted by incorporating auxiliary constraints that include anisotropic diffusion and trigonometric color space polarization. These constraints enforce
edge-preserving texture matching
and eliminate artifacts such as red discontinuity through explicit color loss terms like Lcol. -
The system can perform real-time, high-fidelity image restoration across four major degradation tasks: low-light (LLIE), underwater (UIE), backlit (BAID), and fundus enhancement (FIE). This is demonstrated by achieving
state-of-the-art performance across 15 datasets covering 4 tasks on 10 metrics against baselines.
Abstract
Current approaches for restoration of degraded images face a trade-off: high-performance models are slow for practical use, while fast models produce poor results. Knowledge distillation transfers teacher knowledge to students, but existing static feature matching methods cannot capture how modern transformer architectures dynamically generate features. We propose a novel Latent Rectified Flow Feature Distillation method for restoring degraded images called'RestoRect'. We apply rectified flow to reformulate feature distillation as a generative process where students learn to synthesize teacher-quality features through learnable trajectories in latent space. Our framework combines Retinex decomposition with learnable anisotropic diffusion constraints, and trigonometric color space polarization. We introduce a Feature Layer Extraction loss for robust knowledge transfer between different network architectures through cross-normalized transformer feature alignment with percentile-based outlier detection. RestoRect achieves better training stability, and faster convergence and inference while preserving restoration quality, demonstrating superior results across 15 image restoration datasets, covering 4 tasks, on 10 metrics against baselines.
Sources
- Optimizing Knowledge Distillation in Transformers: Enabling Multi-Head Attention without Alignment Barriers
- Reti-Diff: Illumination Degradation Image Restoration with Retinex-based Latent Diffusion Model
- UnfoldIR: Rethinking Deep Unfolding Network in Illumination Degradation Image Restoration
- Distilling the Knowledge in a Neural Network
- Imagen Video: High Definition Video Generation with Diffusion Models
- Like What You Like: Knowledge Distill via Neuron Selectivity Transfer
- TinyBERT: Distilling BERT for Natural Language Understanding
- Flow Straight and Fast: Learning to Generate and Transfer Data with Rectified Flow
- FitNets: Hints for Thin Deep Nets
- Deep Retinex Decomposition for Low-Light Enhancement
- You Only Need One Color Space: An Efficient Network for Low-light Image Enhancement
- HVI-CIDNet+: Beyond Extreme Darkness for Low-Light Image Enhancement
- Consistency Flow Matching: Defining Straight Flows with Velocity Consistency
- Paying More Attention to Attention: Improving the Performance of Convolutional Neural Networks via Attention Transfer
- Low-Light Image and Video Enhancement: A Comprehensive Survey and Beyond
Related papers
- Loss Knows Best: Detecting Annotation Errors in Videos via Loss Trajectories
- AnchorWeave: World-Consistent Video Generation with Retrieved Local Spatial Memories
- Benchmarking the Robustness of Foundation Models for Mammography under Domain Shift
- MambaX-Net: Dual-Input Mamba-Enhanced Cross-Attention Network for Longitudinal MRI Segmentation
- TeleOCR: Navigating Document Parsing Across Digital and Camera-Captured Documents
- A Survey on Efficient Vision-Language-Action Models