Hi everyone, I used matplotlib in my project but I encounted a problem and I can't know what happend exactly. Here is my command line:
App\python.exe file\contour.py "C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\print.out" 0 15000
and when I excuted, I got an error:
self.tk.call(('image', 'create', imgtype, name,) + options)
_tkinter.TclError:
couldn't open "C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\程序源码\PFOR3D\Release\For3D_Demo\PortablePython\App\lib\site-packages\matplotlib\mpl-data\images\matplotlib.gif":
no such file or directory
current directory is
C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\程序源码\PFOR3D\Release\For3D_Demo\PortablePython>
I used this in Portable Python whose python version is 2.7.6 and the matplotlib version is 1.3.1. Actually I got a result when the environment path does not have any Chinese charactors. eg. C:\PortablePython\
C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\程序源码\PFOR3D\Release\For3D_Demo\PortablePython\App\lib\site-packages\matplotlib\mpl-data\images\matplotlib.gif
should exist -- it is distributed as part of matplotlib. One of the ways this sometimes happens is if you install one version of matplotlib on top of another. You could try deleting C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\程序源码\PFOR3D\Release\For3D_Demo\PortablePython\App\lib\site-packages\matplotlib\ and reinstalling matplotib or reinstalling your Python environment.
Hey, mdboom, thanks for your comment. But I think there maybe some misunderstanding.
I didn't install any other version of matplotlib and I also checked the file matplotlib.gif, it does exist. I didn't change any thing of matplotlib.
I used this in Portable Python whose python version is 2.7.6 and the matplotlib version is 1.3.1. Actually I got a result when the environment path does not have any Chinese charactors. eg. C:\PortablePython\
looking forward to any solution
Might this be a bug in tk? Using conda + python3 + non-ascii path it works correctly, but trying to to the same thing with python2 gives me errors even starting up python.
Activity
mdboom commented on Nov 3, 2015
C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\程序源码\PFOR3D\Release\For3D_Demo\PortablePython\App\lib\site-packages\matplotlib\mpl-data\images\matplotlib.gif
should exist -- it is distributed as part of matplotlib. One of the ways this sometimes happens is if you install one version of matplotlib on top of another. You could try deleting C:\Documents and Settings\fanping\桌面\FOR3D_PARALLEL\程序源码\PFOR3D\Release\For3D_Demo\PortablePython\App\lib\site-packages\matplotlib\ and reinstalling matplotib or reinstalling your Python environment.
zsynacl commented on Nov 4, 2015
Hey, mdboom, thanks for your comment. But I think there maybe some misunderstanding.
I didn't install any other version of matplotlib and I also checked the file matplotlib.gif, it does exist. I didn't change any thing of matplotlib.
mdboom commented on Nov 4, 2015
How did you install matplotlib? Whatever method you used seems to have missed that file.
zsynacl commented on Nov 4, 2015
nope, I used portable python. I ensure that the file matplotlib.gif is just there.

tacaswell commented on Nov 4, 2015
Might this be a bug in tk? Using conda + python3 + non-ascii path it works correctly, but trying to to the same thing with python2 gives me errors even starting up python.
Can you try with any python 3.4 or 3.5?
zsynacl commented on Nov 4, 2015
hey tacaswell, I can't control the environment. Maybe I should just suggest the user to use English-only path...
anntzer commented on Jan 3, 2019
matplotlib.gif no longer exists since #5626.