Skip to content

Commit

Permalink
actually define max_wavelength and min_ when making spectral_data
Browse files Browse the repository at this point in the history
  • Loading branch information
HaleySchuhl committed May 20, 2024
1 parent 61c76c0 commit c9fa331
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plantcv/geospatial/read_geotif.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ def read_geotif(filename, bands="B,G,R"):

# Make a Spectral_data instance before calculating a pseudo-rgb
spectral_array = Spectral_data(array_data=img_data,
max_wavelength=None,
min_wavelength=None,
max_wavelength=max(wavelengths, key=wavelengths.get),
min_wavelength=min(wavelengths, key=wavelengths.get),
max_value=np.max(img_data), min_value=np.min(img_data),
d_type=img.dtypes[0],
wavelength_dict=wavelengths, samples=int(width),
Expand Down

0 comments on commit c9fa331

Please sign in to comment.