Skip to content

segusantos/rsrcnn

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RSRCNN

Comparison Results Comparison Results

Visual comparison of x2 super-resolution results showing Ground Truth, Bicubic Interpolation, FSRCNN and RSRCNN images

This repository contains the implementation of the Residual Super-Resolution Convolutional Neural Network (RSRCNN), as well as the baseline Fast Super-Resolution Convolutional Neural Network (FSRCNN) model, introduced in the paper Accelerating the Super-Resolution Convolutional Neural Network.

RSRCNN builds upon the FSRCNN architecture by replacing the non-linear mapping layer with a residual block and adding skip connections, improving performance in image super-resolution tasks.

The models are implemented in PyTorch and trained on standard datasets such as DIV2K, T91, General100, and BSD100. The repository includes trained weights for both FSRCNN and RSRCNN models at x2 and x4 upscaling factors.

Moreover, this work explores the impact of different loss functions to the default MSE loss on super-resolution performance. In particular, it introduces Negative PSNR and Complementary SSIM (CSSIM) losses, which are designed to better align the training objective with perceptual image quality and yield improved results in terms of PSNR and SSIM metrics.

The full paper and poster can be found in the docs directory.

Usage

The repository includes scripts for training both the baseline FSRCNN and the RSRCNN models, evaluating their performance, visualizing results and testing them in real-time using a webcam. The project uses uv for dependency management.

  • Install the required dependencies:

    uv sync --locked
  • Build a super-resolution dataset for a given set of images, upscaling factor and patch size:

    uv run -m scripts.dataset
  • Train a model with a specified architecture, size, upscaling factor and loss function:

    uv run -m scripts.train
  • Evaluate model performance on test datasets:

    uv run -m scripts.eval
  • Visualize and plot comparison results:

    uv run -m scripts.plot
  • Test the model in real-time using your webcam:

    uv run -m scripts.realtime

About

Residual Super-Resolution Convolutional Neural Network

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages