I’m trying to create a GIF but I get an error. I’m under Windows 10 (but it does it also under Linux [Ubuntu])
could not spawn `ffmpeg -v 0 -i 'C:\Users\...\AppData\Local\Temp\jl_C8B5.tmp/%06d.png' -vf palettegen=stats_mode=diff -y 'C:\Users\...\AppData\Local\Temp\jl_C8B5.tmp/palette.bmp'`: no such file or directory (ENOENT)
Do I need to add some package in oder to make it works ?
Just in case, there is the code I’m using (not mine)
using Plots
# initialize the attractor
n = 1500
dt = 0.02
σ, ρ, β = 10., 28., 8/3
x, y, z = 1., 1., 1.
# initialize a 3D plot with 1 empty series
plt = path3d(1, xlim=(-25,25), ylim=(-25,25), zlim=(0,50),
xlab = "x", ylab = "y", zlab = "z",
title = "Lorenz Attractor", marker = 1)
# build an animated gif, saving every 10th frame
@gif for i=1:n
dx = σ*(y - x) ; x += dt * dx
dy = x*(ρ - z) - y ; y += dt * dy
dz = x*y - β*z ; z += dt * dz
push!(plt, x, y, z)
end every 10
Perhaps the installer didn’t add the install directory to your PATH? If you run ffmpeg from the CMD console does it run? If you you can edit your PATH environment variable to include the folder with the ffmpeg.exe binary.
This give this message julia> run(ffmpeg -version) ERROR: could not spawn 'ffmpeg -version': no such file or directory (ENOENT) in _jl_spawn at ./process.jl:262
OK, so I assume that running ffmpeg -version from a console doesn’t work either. Did the installation really go well? On Ubuntu the sudo apt-get install ffmpeg should have just worked. Alternatively, editing the system path @ssfrr mentioned might help.
ERROR: LoadError: could not spawn `wkhtmltoimage -f png -q --width 600 --height 400 --disable-smart-width /tmp/julia5mfgPr.html /tmp/julia2yPH6Q.png`: no such file or directory (ENOENT)
in _jl_spawn at ./process.jl:262
while loading /media/.../...//attractor.jl, in expression starting on line 15
It doesn’t work either. As for the sudo apt-get, well I’m not allowed to used it since it’s not my computer, they didn’t give me the rights to do so. But according to Synaptic, ffmpeg is already installed
If ffmpeg is installed you should be able to open a terminal and just run ffmpeg -version. If you can’t then something else is not working. I guess you could install ffmpeg locally and not systenm-wide (from source?), but that seems involved. Hmmm…