Closed
Description
Bug report
Bug summary
When I try to save an animation using imagemagick to write to a gif, the saving works perfectly, but the message MovieWriter imagemagick unavailable.
is printed to the console.
Code for reproduction
from matplotlib.animation import FuncAnimation
import matplotlib.pyplot as plt
import numpy as np
x = np.linspace(0, 1, 20)
def f(x, i):
return x*np.sin(i/10)
line, = plt.plot(x, f(x, 0))
plt.xlim([0,1])
plt.ylim([-1,1])
fig = plt.gcf()
def animate(i):
line.set_data(x, f(x,i))
anim = FuncAnimation(fig, animate, frames=60, interval=50)
anim.save('fig.gif', writer='imagemagick')
plt.show()
Actual outcome
MovieWriter imagemagick unavailable.
Yet, the gif is still produced.
Expected outcome
The gif is produced without lying to me about the unavailability of imagemagick.
Matplotlib version
- Operating system: Windows 10 Version 1803
- Matplotlib version: 2.2.2
- Matplotlib backend (
print(matplotlib.get_backend())
): Qt5Agg - Python version: 3.6.5 (installed with conda)
- Other libraries: imagemagick 7.0.8.7 (installed with chocolatey)
I suspect this has to do with that way that I've installed imagemagick, since chocolatey shims "magick" into the PATH, and matplotlib looks through the registry.