-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Metrics review #13
Metrics review #13
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
""" | ||
Structural SIMularity index | ||
""" | ||
_assert_image_shapes_equal(org_img, pred_img, "SSIM") | ||
|
||
return structural_similarity(org_img, pred_img, data_range=data_range, multichannel=True) | ||
return structural_similarity(org_img, pred_img, data_range=max_p, multichannel=True) | ||
|
||
|
||
def sliding_window(image, stepSize, windowSize): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The question of the processing time,
- should we make the step size and window size exposed in the parameters? Just in case we want to speed it up
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea. Did that.
BTW, it might now be faster as the compute-intensive operations only have to consider one band and not all of them.
# The original paper states that SAM values are expressed as radians, while e.g. Lanares | ||
# et al. (2018) use degrees. We therefore made this configurable, with degree the default |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
* <i><a href="https://en.wikipedia.org/wiki/Root-mean-square_deviation">Root mean square error (RMSE)</a></i>, | ||
* <i><a href="https://en.wikipedia.org/wiki/Peak_signal-to-noise_ratio">Peak signal-to-noise ratio (PSNR)</a></i>, | ||
* <i><a href="https://en.wikipedia.org/wiki/Structural_similarity">Structural Similarity Index (SSIM)</a></i>, | ||
* <i><a href="https://www4.comp.polyu.edu.hk/~cslzhang/IQA/TIP_IQA_FSIM.pdf">Feature-based similarity index (FSIM)</a></i>, | ||
* <i><a href="https://www.tandfonline.com/doi/full/10.1080/22797254.2019.1628617">Information theoretic-based Statistic Similarity Measure (ISSM)</a></i>, | ||
* <i><a href="https://www.sciencedirect.com/science/article/abs/pii/S0924271618302636">Signal to reconstruction error ratio (SRE)</a></i>, | ||
* <i><a href="https://ntrs.nasa.gov/citations/19940012238">Spectral angle mapper (SAM)</a></i>, and | ||
* <i><a href="https://ece.uwaterloo.ca/~z70wang/publications/quality_2c.pdf">Universal image quality index (UIQ)</a></i> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome!
LGTM |
Checking each of the metrics so we have peace of mind that these implementations are 100% correct or at least ambiguities are documented.
All values are reasonable now with the exception of UIQ which dropped by about 50 %. Can you please have a thorough look if I introduced an error there?