GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Simple-code/metric/ssim_and_psnr at main · mcodare709/Simple-code

Expand file tree

/

ssim_and_psnr

/
Copy path

Directory actions

More options

More options

Directory actions

More options

More options

Latest commit

 

History

History
History
/

ssim_and_psnr

/
Copy path

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
README.md
README.md
 
 
metric.py
metric.py
 
 
psnr.py
psnr.py
 
 
ssim.py
ssim.py
 
 

README.md

Outline

Image Quality Assessment Tools

Image quality evaluation tools for image restoration, enhancement, denoising, and super-resolution.

Supported Metrics

  • SSIM (Structural Similarity Index)
  • PSNR (Peak Signal-to-Noise Ratio)

Installation

pip install opencv-python scikit-image torch torchmetrics

Usage

SSIM

python SSIM.py --input pred.png --gt gt.png

PSNR

python PSNR.py --input pred.png --gt gt.png

SSIM + PSNR

python Metric.py --input pred_dir --gt gt_dir

Arguments

Argument Description
--input Input image or folder
--gt Ground Truth image or folder
--gray Convert to grayscale
--resize Resize input to GT size
--csv Export results to CSV

References

[1] Z. Wang and A. C. Bovik, Mean squared error: Love it or leave it? A new look at signal fidelity measures, IEEE Signal Processing Magazine, 2009.

[2] Z. Wang, A. C. Bovik, H. R. Sheikh, and E. P. Simoncelli, Image quality assessment: From error visibility to structural similarity, IEEE Transactions on Image Processing, 2004.

You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.