Python Matplotlib add_轴在jupyterlab中无法精确工作
考虑以下代码Python Matplotlib add_轴在jupyterlab中无法精确工作,python,matplotlib,jupyter-lab,Python,Matplotlib,Jupyter Lab,考虑以下代码 import matplotlib import matplotlib.pyplot as plt print("Version: ",matplotlib.__version__) fig = plt.figure(figsize=(5,5),facecolor="gray") ax1 = fig.add_axes([0., 0., 1, 1],facecolor="white") plt.savefig(&quo
import matplotlib
import matplotlib.pyplot as plt
print("Version: ",matplotlib.__version__)
fig = plt.figure(figsize=(5,5),facecolor="gray")
ax1 = fig.add_axes([0., 0., 1, 1],facecolor="white")
plt.savefig("test.png")
plt.show()
我只想让轴填充整个图形,但不知怎么的,它是在jupyter实验室收缩的。尽管输出“test.png”还可以。我该如何解决这个问题?