ImageView.__str__ prints the bands element of the RGB metadata; however, this metadata element is not present if class labels are being viewed without an associated image data array. For example:
>>> v = spy.imshow(classes=gt)
>>> v
/home/thomas/src/spectral/spectral/graphics/spypylab.pyc in __str__(self)
1117 meta = self.data_rgb_meta
1118 s = 'ImageView object:\n'
-> 1119 s += ' {0:<20}: {1}\n'.format("Display bands", meta['bands'])
1120 if self.interpolation == None:
1121 interp = "<default>"
KeyError: u'bands'
ImageView.__str__
prints thebands
element of the RGB metadata; however, this metadata element is not present if class labels are being viewed without an associated image data array. For example: