Skip to content
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

16 bit grayscale image support #373

Open
narbhar opened this issue Oct 5, 2023 · 1 comment
Open

16 bit grayscale image support #373

narbhar opened this issue Oct 5, 2023 · 1 comment
Labels
feature New feature or request

Comments

@narbhar
Copy link

narbhar commented Oct 5, 2023

Is your feature request related to a problem? Please describe.
The image metrics implemented all seem to be restricted to consume 8 bit images as indicated by the data_range values. Could this be extended to native 16-bit grayscale images?

Describe the solution you'd like
Extending computation to 16-bit grayscale images by amending the metric implementation

Describe alternatives you've considered
The way to process 16 bit grayscale images alternatively would be to convert them into 8bit images although this would mean compressed images.

@narbhar narbhar added the feature New feature or request label Oct 5, 2023
@zakajd
Copy link
Collaborator

zakajd commented Jan 10, 2024

Hi! Thanks for the proposal. Indeed, most of the metrics only work with 8 bit images, because that's how original authors implementation was written. It's actually not straightforward to port all metrics to higher bit depth, because many of them contain fine-tuned weights / parameters that were estimated with 8 bit RGB.

The easiest way of using the current code would be to manually specify the data range, e.g. set it to 65536 when passing 16 bit images.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants