Plotting Matrices
A given matrix can be plotted using 2D contour plot on a surface.
gnuplot.imagesc(z, ['color' or 'gray'])
Plot surface z using contour plot. The second argument defines
the color palette for the display. By default, grayscale colors are
used, however, one can also use any color palette available in
Gnuplot.
x = torch.linspace(-1,1) xx = torch.Tensor(x:size(1),x:size(1)):zero():addr(1,x,x) xx = xx*math.pi*6 gnuplot.imagesc(torch.sin(xx),'color')
