Skip to content

HeleenaRobert/super-resolution-showcase

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🌟 Super-Resolution Showcase

Banner

Python OpenCV License: MIT Made with Love By HeleenaRobert

A visual benchmark of four deep learning models for Single Image Super-Resolution (SISR) using OpenCV's DNN module. This project compares model quality, runtime, and scale factors in a clear, reproducible format.


πŸ” Overview

This project demonstrates the effectiveness of:

  • EDSR
  • ESPCN
  • FSRCNN
  • LapSRN

Each model is tested at 4Γ— upscaling. Output comparisons help you evaluate both visual clarity and performance runtime.

πŸ’‘ While all scale models (x2, x3, x4) are included in the models/ folder for reference, the demo scripts use only x4 models for consistency.
πŸ”Έ LapSRN does not support x3, but includes a unique x8 model.


πŸš€ Key Features

  • πŸ”§ Easy-to-use demos for all 4 models
  • πŸ“Š Runtime comparison for each model
  • πŸ–ΌοΈ Side-by-side visual quality output
  • πŸ—‚οΈ Modular, reusable utils structure

🧠 How It Works

  1. Load the super-resolution model using OpenCV’s DNN module
  2. Upscale a given low-resolution input
  3. Compare results visually and numerically
  4. Save all outputs in the assets/ folder

πŸ“‚ Folder Structure

super-resolution-showcase/
β”‚
β”œβ”€β”€ assets/                           # Output, runtime and quality samples, banner
β”‚   β”œβ”€β”€ quality_comparison.png
β”‚   β”œβ”€β”€ runtime_chart.png
β”‚   β”œβ”€β”€ model_output.png
β”‚   └── banner.png
β”‚
β”œβ”€β”€ input/                            # Low-res input images
β”‚   β”œβ”€β”€ bike-200.png
β”‚   β”œβ”€β”€ car.jpg
β”‚   β”œβ”€β”€ car-low.jpg
β”‚   β”œβ”€β”€ kitten-200.png
β”‚   └── path-low.jpg
β”‚ 
β”œβ”€β”€ output/                           # All program output images are saved here
β”‚
β”œβ”€β”€ ground_truth/                     # High-res originals for quality reference
β”‚   β”œβ”€β”€ bike-800.png
β”‚   β”œβ”€β”€ car-high.jpg
β”‚   └── path-high.jpg
β”‚ 
β”œβ”€β”€ models/                           # Pre-trained model files (.pb)
β”‚   β”œβ”€β”€ edsr/    
β”‚   β”‚   β”œβ”€β”€ EDSR_x2.pb
β”‚   β”‚   β”œβ”€β”€ EDSR_x3.pb
β”‚   β”‚   └── EDSR_x4.pb
β”‚   β”‚ 
β”‚   β”œβ”€β”€ espcn/    
β”‚   β”‚   β”œβ”€β”€ ESPCN_x2.pb
β”‚   β”‚   β”œβ”€β”€ ESPCN_x3.pb
β”‚   β”‚   └── ESPCN_x4.pb
β”‚   β”‚ 
β”‚   β”œβ”€β”€ fsrcnn/  
β”‚   β”‚   β”œβ”€β”€ FSRCNN_x2.pb
β”‚   β”‚   β”œβ”€β”€ FSRCNN_x3.pb
β”‚   β”‚   └── FSRCNN_x4.pb
β”‚   β”‚ 
β”‚   └── lapsrn/   
β”‚       β”œβ”€β”€ LapSRN_x2.pb
β”‚       β”œβ”€β”€ LapSRN_x4.pb
β”‚       └── LapSRN_x8.pb
β”‚
β”œβ”€β”€ utils/
β”‚   β”œβ”€β”€ visualizer.py
β”‚   └── superres_utils.py            # Core model loader and inference logic
β”‚
β”œβ”€β”€ demo_all_models.py               # Run all models on sample inputs
β”œβ”€β”€ compare_runtime.py               # Time performance of each model
β”œβ”€β”€ compare_quality.py               # Save visual outputs for comparison
β”‚ 
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ .gitignore
β”œβ”€β”€ LICENSE
└── README.md

πŸ§ͺ Demo Scripts

Run all models:

python demo_all_models.py

Compare runtime:

python compare_runtime.py

Compare visual outputs:

python compare_quality.py

πŸ“ All outputs are saved inside the output/ folder.


πŸ–ΌοΈ Sample Output Gallery

⚑ Super resolution model output

Model Output

πŸ“Š Runtime comparison

Comparison

πŸ–ΌοΈ visual analysis

Analysis


πŸ“¦ Requirements

Install required libraries:

pip install -r requirements.txt

πŸͺͺ License

This project is open-source under the MIT License


πŸ™‹β€β™€οΈ Author

Heleena Robert
GitHub

Releases

No releases published

Packages

 
 
 

Contributors

Languages