-
Hello, As mentioned here, I am interested in processing DNGs from RPi cameras (either V2 or HQ), with the ultimate goal of determining the average color of the image. I'm hoping to perform some of the steps listed here, and after completing this tutorial think I know how to use rawpy to do so. A few initial questions below:
Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 0 comments
-
Calling rawpy.imread() and accessing Regarding metadata read from the file (or computed) by libraw, see https://letmaik.github.io/rawpy/api/rawpy.RawPy.html, e.g. Vignetting correction (lens shading) is indeed supported by lensfunpy (or rather the underlying lensfun library), but it looks like there are no profiles available for RPi: https://wilson.bronger.org/lensfun_coverage.html. You can create your own profiles with manual calibration (https://wilson.bronger.org/lens_calibration_tutorial/) but this may possibly be too much work. |
Beta Was this translation helpful? Give feedback.
Calling rawpy.imread() and accessing
.raw_image
leads only to calling libraw'sopen_file()
andunpack()
, see also https://www.libraw.org/docs/API-CXX.html#unpack.Note that the docs mention "Data reading is sometimes (not frequently) affected by settings made in imgdata.params". See https://www.libraw.org/docs/API-notes.html#imgdata_params for details. rawpy does not allow to modify those settings prior to loading, which is an intentional restriction to keep the Python API simple since this is very rarely of use. I think in your case this shouldn't make a difference.
For further questions on how the raw file data relates to the data exposed by
open_file()
/unpack()
you'd have to ask in the…