def showrgb(r,g=None,b=None): if g is None: g = r if b is None: b = r imshow(array([r,g,b]).transpose([1,2,0]))