You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Does not work on windows 7 using VERSION 1.3.1 of matplotlib.
Sample code
# -*- coding: utf-8 -*-"""Created on Thu Dec 11 11:52:11 2014@author: amphttp://matplotlib.org/examples/index.html#examples-index"""# This example uses a MovieWriter directly to grab individual frames and# write them to a file. This avoids any event loop integration, but has# the advantage of working with even the Agg backend. This is not recommended# for use in an interactive setting.# -*- noplot -*-importnumpyasnpimportmatplotlibmatplotlib.use("Agg")
importmatplotlib.pyplotaspltimportmatplotlib.animationasmanimationFFMpegWriter=manimation.writers['ffmpeg']
metadata=dict(title='Movie Test', artist='Matplotlib',
comment='Movie support!')
writer=FFMpegWriter(fps=15, metadata=metadata)
fig=plt.figure()
l, =plt.plot([], [], 'k-o')
plt.xlim(-5, 5)
plt.ylim(-5, 5)
x0,y0=0, 0withwriter.saving(fig, "writer_test2.ogv", 100):
foriinrange(100):
x0+=0.1*np.random.randn()
y0+=0.1*np.random.randn()
l.set_data(x0, y0)
writer.grab_frame()
This may be related to an upgrade in ubuntu and ffmpeg.
See this issue:
matplotlib/matplotlib#2764
The text was updated successfully, but these errors were encountered: