def __init__(self, mat, cmap=None, pixelspervalue=20, minvalue=None, maxvalue=None):
        if minvalue == None:
            minvalue = amin(mat)
        if maxvalue == None:
            maxvalue = amax(mat)
        if not cmap:
            cmap = cm.hot

        figsize = (array(mat.shape) / 100. * pixelspervalue)[::-1]
        self.fig = figure(figsize=figsize)
        axes([0, 0, 1, 1]) # Make the plot occupy the whole canvas
        axis('off')
        self.fig.set_size_inches(figsize)
        imshow(mat, cmap=cmap, clim=(minvalue, maxvalue), interpolation='nearest')
Make a colormap image of a matrix
dataset/ETHPy150Open pybrain/pybrain/pybrain/tools/plotting/colormaps.py/ColorMap.__init__