我正在尝试调用matplotlib.animation.ArtistAnimation来从一系列png图像制作动画,但是我得到一个连接到ffmpeg的错误。我在我的Ubuntu 14.04上安装了Anaconda。我得到的错误消息是:
UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
warnings.warn('Matplotlib is building the font cache using fc-list. This may take a moment.')
/home/ohm/anaconda2/lib/python2.7/site-packages/matplotlib/animation.py:782: UserWarning: MovieWriter ffmpeg unavailable
warnings.warn("MovieWriter %s unavailable" % writer)
...
File "/home/ohm/anaconda2/lib/python2.7/site-packages/matplotlib/animation.py", line 810, in save
writer.grab_frame(**savefig_kwargs)
File "/home/ohm/anaconda2/lib/python2.7/contextlib.py", line 24, in __exit__
self.gen.next()
File "/home/ohm/anaconda2/lib/python2.7/site-packages/matplotlib/animation.py", line 196, in saving
self.finish()
File "/home/ohm/anaconda2/lib/python2.7/site-packages/matplotlib/animation.py", line 389, in finish
+ ' Try running with --verbose-debug')
RuntimeError: Error creating movie, return code: 1 Try running with --verbose-debug
我已经尝试了sudo apt-get install ffmpeg
,但没有这样的套餐。有人知道我错过了什么方案吗?
答案 0 :(得分:4)
conda update conda
conda install --channel https://conda.anaconda.org/conda-forge ffmpeg