可能重复:
matplotlib.animation error - The system cannot find the file specified
我正在尝试在python中使用动画类,并且save.animation
函数有问题。其他问题让海报在python路径中添加了一个名为ffmpeg.exe
的应用程序来解决问题。
不幸的是,我真的不明白“在python路径中添加一些内容”意味着什么,并且无法通过在线搜索来解决这个问题。
有人想开导我吗?非常感谢!
问题是当我的代码运行时:
anim.save('HAMILTONIAN.mp4',fps=5, codec=None, clear_temp=True,
frame_prefix='_tmp')
产生错误:
Traceback (most recent call last):
File "Z:\desktop\Project\bhmqntm-code\HamiltonianMovie(points_reducedtsegs).py", line 75, in <module>
anim.save('HAMILTONIAN.mp4',fps=5, codec=None, clear_temp=True, frame_prefix='_tmp')
File "C:\Python27\lib\site-packages\matplotlib\animation.py", line 127, in save
self._make_movie(filename, fps, codec, frame_prefix)
File "C:\Python27\lib\site-packages\matplotlib\animation.py", line 164, in _make_movie
stdout=PIPE, stderr=PIPE)
File "C:\Python27\lib\subprocess.py", line 679, in __init__
errread, errwrite)
File "C:\Python27\lib\subprocess.py", line 893, in _execute_child
startupinfo)
WindowsError: [Error 2] The system cannot find the file specified