【Plt 绘图保存错误】AttributeError: module ‘backend_interagg‘ has no attribute ‘FigureCanvas‘

问题

使用 plt.savefig() 时报错:

AttributeError: module ‘backend_interagg‘ has no attribute ‘FigureCanvas‘

解决 

Matplotlib 的版本过高,需要降低:

pip uninstall matplotlib
pip install matplotlib==3.5.0

猜你喜欢

转载自blog.csdn.net/Mercury_Lc/article/details/127654199