The NRMSE (normalized root mean square error) - reference-based image metric.
- Source:
Members
(static) defaultTolerance
The allowed size difference when comparing images.
The leftover extra pixels of the larger image will be ignored.
- Source:
(static) pixelMaxValue
The maximum value of a pixel component. 255 for 8 bit depth
- Source:
Methods
(static) compare(image1, image2, tolerance)
Compares two images.
Parameters:
Name | Type | Description |
---|---|---|
image1 |
* | Preferably the ground truth / reference (convention, shouldnt matter otherwise) |
image2 |
* | An image to compare |
tolerance |
* | The allowed size ratio difference, default is NRMSE.defaultTolerance . |
- Source:
Returns:
An object with the calculate metric values of MSE, PSNR, RMSE, NRMSE,
Inverted NRMSE, NMSE, and Inverted NMSE.
(static) log10()
Utility function that performs a Log base 10 calculation.
- Source:
(static) psnr(mse, max)
Calculates PSNR (Peak Signal-to-Noise Ratio).
Parameters:
Name | Type | Description |
---|---|---|
mse |
* | a Mean Squared Error (MSE) value |
max |
* | the maximum value of a pixel component, default is NRMSE.pixelMaxValue |
- Source:
Returns:
the calculated value