raise NeedDownloadError('Need ffmpeg exe. ' NeedDownloadError: Need ffmpeg exe)
Solution 1
This package relies on the ffmpeg
executable to be in the PATH.
So just download it, install it somewhere, and add installation directory to PATH. make sure it can be accessed by typing:
ffmpeg
from the command line.
Solution 2
Those final two lines in the error messages provide a valuable clue, and I installed moviepy only today so I remember a remedy.
NeedDownloadError: Need ffmpeg exe. You can download it by calling:
imageio.plugins.ffmpeg.download()
- First
(sudo) pip install imageio
, if necessary. - Now:
import imageio
and thenimageio.plugins.ffmpeg.download()
.
Solution 3
If you are using Ubuntu just try:
sudo apt-get install ffmpeg
Else if you are using Windows just try to change ffmpeg.py 82th line from auto=False to auto=True
It will automatically download ffmpeg to the correct path once. Then import imageio
and write down imageio.plugins.ffmpeg.download()
Will work.
Solution 4
For anyone using a mac do this.
pip install imageio (if not already installed).
Then create a .py file (python script).
In this file write this:
import imageio
imageio.plugins.ffmpeg.download()
Run this script in the terminal (i.e "python (insert .py filename here)" )
It installs FFmpeg in a directory that should be automatically added to your path. If not, add it to your path.
Then type
ffmpeg
to make sure it's installed in your path.
Related videos on Youtube
Comments
-
Pablo about 2 years
I'm trying to execute a call to an unofficial Instagram API python library, after several errors for dependencies needed I fixed, I'm stuck at this one.
File "C:\Users\Pablo\Desktop\txts_pys_phps_programacion\Instagram-API-python-master\InstagramAPI.py", line 15, in <module> from moviepy.editor import VideoFileClip File "C:\Python27\lib\site-packages\moviepy\editor.py", line 22, in <module> from .video.io.VideoFileClip import VideoFileClip File "C:\Python27\lib\site-packages\moviepy\video\io\VideoFileClip.py", line 3, in <module> from moviepy.video.VideoClip import VideoClip File "C:\Python27\lib\site-packages\moviepy\video\VideoClip.py", line 20, in <module> from .io.ffmpeg_writer import ffmpeg_write_image, ffmpeg_write_video File "C:\Python27\lib\site-packages\moviepy\video\io\ffmpeg_writer.py", line 15, in <module> from moviepy.config import get_setting File "C:\Python27\lib\site-packages\moviepy\config.py", line 38, in <module> FFMPEG_BINARY = get_exe() File "C:\Python27\lib\site-packages\imageio\plugins\ffmpeg.py", line 86, in get_exe raise NeedDownloadError('Need ffmpeg exe. ' NeedDownloadError: Need ffmpeg exe. You can download it by calling: imageio.plugins.ffmpeg.download()
-
Jean-François Fabre over 7 years@BillBell thanks. Though, to be devil's advocate, in some cases it is required, when the answer is clearly wrong.
-
Jean-François Fabre over 7 yearsso this method doesn't need to put
ffmpeg
in the path I guess? I suppose that the executable is put in some python directory where it can be called from. -
Bill Bell over 7 yearsNo, I didn't have to do anything else. Pure magic. I always end my efforts when the error messages go away. ;)
-
Jean-François Fabre over 7 yearsI use
ffmpeg
directly so it is in my path. I guess that made me ignore the error message (that clearly appears in the OP traceback). I think OP should accept _your_answer. -
Bill Bell over 7 years@Jean-FrançoisFabre: We'll see what happens. No worries AFAIAC.
-
xslittlegrass over 7 yearsmagic indeed! I'm on a cluster and don't have root right, but this solution still works.