savefig without frames, axes, only content
EDIT Changed aspect=”normal to aspect=”auto’ since that changed in more recent versions of matplotlib (thanks to @Luke19). Assuming : import matplotlib.pyplot as plt To make a figure without the frame : fig = plt.figure(frameon=False) fig.set_size_inches(w,h) To make the content fill the whole figure ax = plt.Axes(fig, [0., 0., 1., 1.]) ax.set_axis_off() fig.add_axes(ax) Then draw your … Read more