Sör*_*ren 6 wxpython matplotlib python-2.7
我在anaconda环境中使用python.当我导入matplotlib时,我遇到了与xwpython的兼容性问题.所以,我想切换后端.通常,这将使用matplotlibrc文件完成.但是,似乎~/.config/matplotlib/
忽略了matplotlibrc .是否可以检查在导入matplotlib期间是否使用了matplotlibrc文件?使用python 2.7.
您可以使用以下命令获取文件路径:
import matplotlib
print(matplotlib.matplotlib_fname())
Run Code Online (Sandbox Code Playgroud)
在我的情况下返回:
'/Users/m300241/.matplotlib/matplotlibrc'