Skip to content

What is SSIM's output range? #31

Answered by francois-rozet
ljeonjko asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @ljeonjko 👋,

I had to think about it, but the output range of SSIM is [-1, 1]. Indeed, for the first term, if x and y are positives, the range is [0, 1], but the contrast sensitivity (CS) is some kind of correlation between x and y, which means it ranges from -1 to 1.

However, this does not change anything if you want a loss function. Any function of the type a - b * ssim(x, y), with b strictly positive, would have gradients in the correct direction.

P.S. I could not find the previous discussion where this was mentioned. However, it is written in the README that the output range is [0, 1] which I will fix shortly.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by francois-rozet
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants