The scope of this PR was a little broader than expected.
The unanticipated challenge when allowing multiple output data types is that handling the img_type is None case creates too many logical branches and the standard if else clutter for no real benefit. The simplest thing to do was change img_type from a kwarg to a positional argument. Forcing the choice works because there are only 2 potential outputs, and handling the None case with available data just felt like it added confusion especially in the higher level ImageSet.
This PR:
Change Capture.create_aligned_capture() to accept img_type as a positional argument. Simplify radiance/reflectance logic.
Adds Capture.save_capture_as_bands() to meet the original intent. This includes output data type handling, and simplified logic depending on whether user passes 'radiance' or 'reflectance' value.
Update `Capture.save_capture_as_stack() to also accept the new output data type handling.
Update ImageSet to accomodate output data type parameter. Also update img_type to positional argument to match Capture usage. Some docstring improvements.
The scope of this PR was a little broader than expected.
The unanticipated challenge when allowing multiple output data types is that handling the
img_type is None
case creates too many logical branches and the standardif else
clutter for no real benefit. The simplest thing to do was changeimg_type
from akwarg
to a positional argument. Forcing the choice works because there are only 2 potential outputs, and handling theNone
case with available data just felt like it added confusion especially in the higher level ImageSet.This PR:
Capture.create_aligned_capture()
to acceptimg_type
as a positional argument. Simplify radiance/reflectance logic.Capture.save_capture_as_bands()
to meet the original intent. This includes output data type handling, and simplified logic depending on whether user passes'radiance'
or 'reflectance'
value.ImageSet
to accomodate output data type parameter. Also updateimg_type
to positional argument to matchCapture
usage. Some docstring improvements.