The pyplot interface to matplotlib might be the simplest way to close a figure.
matplotlib
import matplotlib.pyplot as plt plt.plot([0, 1], [0, 1]) plt.close()