def __init__(self, data, img_shape, mask=None, use_imag=True, img_all=None, spect_all=None,
parent=None):
super(DialogSVD, self).__init__(parent=parent) ### EDIT ###
self.setup(parent=parent)
self.setupData(img_shape=img_shape)
self.ui_changes()
self.U = data[0]
self.s = data[1]
self.Vh = data[2]
self._n_factors = self.s.size
self.mask = mask
self._use_imag = use_imag # By default, use imag portion of complex data
if (img_all is None) and (spect_all is None):
cube_all = self.combiner(selections=_np.arange(self._n_factors))
self.img_all = self.mean_spatial(cube_all)
self.spect_all = self.mean_spectral(cube_all)
else:
self.img_all = img_all.real
if _np.iscomplexobj(spect_all):
if self._use_imag:
self.spect_all = spect_all.imag
else:
self.spect_all = spect_all.real
else:
self.spect_all = spect_all
self.updatePlots(0)
self.updateCurrentRemainder()
评论列表
文章目录