>>> data[:,:,shape[2]/2]
array([[10204, 11500, 11012, ..., 10472, 10020, 11232],
[13196, 13024, 13868, ..., 12200, 13252, 12676],
[13184, 11932, 13576, ..., 12668, 12256, 13216],
...,
[14496, 13908, 13652, ..., 13816, 14204, 13384],
[14472, 14536, 13900, ..., 13960, 15312, 14460],
[15072, 14856, 14984, ..., 15440, 15528, 15888]], dtype=uint16)
>>> data[:,:,shape[2]/2].shape
(1002, 1004)tex3 = pg.makeRGBA(data[:,:,shape[2]/2], levels=levels)[0] # xy plane
| shape = self.data.shape
| AttributeError: 'tuple' object has no attribute 'shape'
|==============================<<
Error while drawing item <pyqtgraph.opengl.items.GLImageItem.GLImageItem object at 0x10e990c30>.
from skimage import img_as_float
(array... [ 255, 255, 255, 255]]], dtype=uint8), False)
tex1 = pg.makeRGBA(img_as_ubyte(data[shape[0]/2]))[0] # yz plane
tex2 = pg.makeRGBA(img_as_ubyte(data[:,shape[1]/2]))[0] # xz plane
tex3 = pg.makeRGBA(img_as_ubyte(data[:,:,shape[2]/2]))[0] # xy plane