You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Spectral libraries may have more bands than actually needed or may have bands in a non-monotonic order. This issue is to add a filter method to the SpectralLibrary to enable things like:
Selecting a subset of bands from the library
Re-ordering bands to make them monotonically increasing/decreasing
Removing bad bands (e.g., bands identified in the bbl list)
The text was updated successfully, but these errors were encountered:
I think function like that could be generally useful.
Maybe make general purpose functions and call them from spectral library?
I would like to help. For start with first point, selecting a subset of bands from library.
But would like to know, what exactly did you have in mind?
What should this function accept as arguments?
What should in return?
What side effects should it have inside the class?
My initial thought was just to have a simple interface for selecting a subset of bands from a SpectralLibrary, based on keywords or specific band indices. For example:
If the bands are in descending order, one might want to reverse them
If bands are not monotonically increasing (which often happens at detector boundaries), one might either want to sort them or just select the ones that are increasing (i.e., ignore the first few bands of the second detector)
However, the more I've thought about this, I believe it makes sense to have a more general capability so that in addition to selecting/reordering bands from a SpectralLibrary, one could also select/reorder the bands in an associated image. To accomplish that, it is probably best to have the filter-related methods in several classes:
BandInfo
SpectralLibrary
Image
Starting with BandInfo, there should be a method to get a set of band indices, based on either a set of constants ('ascending', 'descending', 'monotonic', etc.) or a callable object that can determine the appropriate order. The return of that method would be the actual band indices (in desired order), which could then be passed to the filter methods of BandInfo, SpectralLibrary, and Image to perform the desired transformation.
Related to this, I've also been toying with the idea of changing the structure of BandInfo so instead of having a fixed set of specific arrays ("centers", "bandwidths", etc.), There could be a single object to manage all the band-specific quantities and then use property decorators to expose the individual attributes.
Spectral libraries may have more bands than actually needed or may have bands in a non-monotonic order. This issue is to add a
filter
method to theSpectralLibrary
to enable things like:bbl
list)The text was updated successfully, but these errors were encountered: