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

get the HDR image in .hdr or .exr format #14

Open
Yliu724 opened this issue Aug 22, 2021 · 4 comments
Open

get the HDR image in .hdr or .exr format #14

Yliu724 opened this issue Aug 22, 2021 · 4 comments

Comments

@Yliu724
Copy link

Yliu724 commented Aug 22, 2021

Thanks for your impressive work!

I have read your code and generate some results using the test.py file. It seems that the reconstructed hdr image is saved as uint16 png format, and in the tonemapped_visualization.py, the hdr image is tone mapped to LDR image for visualization.
Am I right? And I also try to directly save the sr_img to .hdr or .exr format using the following code:
cv2.imwrite('hdr_img_path.hdr', sr_img)
The result seems good. Can I do so to get the HDR image in .hdr or .exr format instead of uint16 png format?

Thank you~

@chxy95
Copy link
Owner

chxy95 commented Aug 22, 2021

@Yliu724 It's OK to do so, but it is better to perform gamma inversion to obtain linear image before saving in a .hdr or .exr format.

@Yliu724
Copy link
Author

Yliu724 commented Aug 23, 2021 via email

@sunyclj
Copy link

sunyclj commented Mar 2, 2022

@chxy95 please, what operation gamma inversion is? thanks.

@chxy95
Copy link
Owner

chxy95 commented Mar 2, 2022

@sunyclj you can refer to this page for an approximate inversion of gamma correction.
https://forum.image.sc/t/how-to-reverse-gamma-correction-from-a-image/9430

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

No branches or pull requests

3 participants