Commit 09473652 authored by Benjamin Jakimow's avatar Benjamin Jakimow
parent ebabe32a
Pipeline #16674 failed with stage
in 1 minute and 27 seconds
......@@ -2413,6 +2413,7 @@ class SpectralLibraryWidget(AttributeTableWidget):
self.actionExportSpeclib.triggered.connect(self.onExportSpectra)
self.tbSpeclibAction = QToolBar('Spectral Profiles')
self.tbSpeclibAction.setObjectName('SpectralLibraryToolbar')
self.tbSpeclibAction.addAction(self.actionSelectProfilesFromMap)
self.tbSpeclibAction.addAction(self.actionAddProfiles)
self.tbSpeclibAction.addAction(self.actionImportSpeclib)
......
......@@ -515,6 +515,9 @@ class EnviSpectralLibraryIO(AbstractSpectralLibraryIO):
continue
xValues, wlu, yUnit = key
# Ann Crabbé: bad bands list
bbl = profiles[0].bbl()
# stack profiles
pData = [np.asarray(p.yValues()) for p in profiles]
pData = np.vstack(pData)
......@@ -523,8 +526,6 @@ class EnviSpectralLibraryIO(AbstractSpectralLibraryIO):
if pData.dtype == np.int64:
pData = pData.astype(np.int32)
# todo: other cases?
profileNames = [p.name() for p in profiles]
if iGrp == 0:
......@@ -560,6 +561,9 @@ class EnviSpectralLibraryIO(AbstractSpectralLibraryIO):
if wlu not in ['', '-', None]:
ds.SetMetadataItem('wavelength units', wlu, 'ENVI')
if bbl not in ['', '-', None]:
ds.SetMetadataItem('bbl', value2hdrString(bbl), 'ENVI')
flushCacheWithoutException(ds)
pathHDR = ds.GetFileList()[1]
......
......@@ -971,7 +971,6 @@ def loadUi(uifile, baseinstance=None, package='', resource_suffix='_rc', remove_
dirUi = os.path.dirname(uifile)
QGIS_QRC = REGEX_QGIS_IMAGES_QRC = re.compile(r'.*QGIS[^\/]*[\/]images[\/]images\.qrc$')
locations = []
for m in re.findall(r'(<include location="(.*\.qrc)"/>)', txt):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment