
Recherche avancée
Médias (1)
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
Autres articles (30)
-
Supporting all media types
13 avril 2011, parUnlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)
-
Configurer la prise en compte des langues
15 novembre 2010, parAccéder à la configuration et ajouter des langues prises en compte
Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...) -
Contribute to translation
13 avril 2011You can help us to improve the language used in the software interface to make MediaSPIP more accessible and user-friendly. You can also translate the interface into any language that allows it to spread to new linguistic communities.
To do this, we use the translation interface of SPIP where the all the language modules of MediaSPIP are available. Just subscribe to the mailing list and request further informantion on translation.
MediaSPIP is currently available in French and English (...)
Sur d’autres sites (3432)
-
FFMPEG and Matplotlib for animations - strange outputs ?
27 juin 2020, par user13132640I'm trying to create animations using FFMPEG and matplotlib. Using the below code, I am creating the FFMpeg writer, and then using a loop, writing a series of graphs to the animation. However, the outputs I'm getting are very strange ; sometimes, when I watch the .mp4 file, the first 5 seconds are blank, then the video "ends" (the playback time on my media player says that it's complete), and at that point, my animation shows up. Other times, some frames are missing or skipped. I've tried searching around, but frankly I haven't found anyone with similar issues.


I just installed the latest version of FFMpeg today.


FFMpegWriter = manimation.writers['ffmpeg']
metadata = dict(title='Animation test', artist='name')
writer = FFMpegWriter(fps=1, metadata=metadata) # 1 frames per second, each year is 1 second



Then, the plotting part...(I've excluded the code where I setup the fig, ax etc.)


with writer.saving(fig, "animation.mp4", dpi=200):
 year = "2005"
 for i in range(4):

 d1_plot = d1[d1['Year'].str.contains(year, na=False)]
 ax.scatter(d1_plot["Lat"], d1_plot["Long"], c='g', s=d1_plot["Size"], transform=ccrs.PlateCarree())
 ax.set_title(year)
 writer.grab_frame()
 year = str(int(year)+1)



-
Python FuncAnimation is saved only 30%
4 mars 2017, par cvutI am trying to make a movie out of data I’ve calculated. I am using ffmpeg writer. When I start the animation in Spyder it is working fine and goes to the end, but when I try to save it it goes only for first 30% of animation. How can I make it to save the whole animation ?
Here is a bit of code( it’s long) ; MM is place where the matrices are stored (1200 of them).
import matplotlib
matplotlib.use("Agg")
from mpl_toolkits.mplot3d import axes3d
import matplotlib.animation as animation
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
nx = 10
ny = 10
X=np.linspace(0, Lx, nx)
Y=np.linspace(0, Ly, ny)
Writer = animation.writers['ffmpeg']
writer = Writer(fps=15, metadata=dict(artist='Me'), bitrate=1)
plt.ion()
fig = plt.figure()
im = plt.contourf(X, Y, MM[0], np.linspace(T_ok,np.max(MM[-1]),150), cmap = cm.hot)
ax = fig.add_subplot(111, projection='3d')
plt.colorbar(im)
def anime(i):
ax.cla()
im = ax.contourf(X, Y, MM[i], np.linspace(T_ok,np.max(MM[-1]),150), cmap = cm.hot)
plt.title('%5.3f'%i)
return im,
anim = animation.FuncAnimation(fig, anime)
anim.save('anime.mp4', writer=writer)EDIT : I just set frames to 10000 and it’s working, but I would like to know why. There are 1200 matrices that should be plotted.
-
Python FuncAnimation is saved only 30%
14 mars 2018, par cvutI am trying to make a movie out of data I’ve calculated. I am using ffmpeg writer. When I start the animation in Spyder it is working fine and goes to the end, but when I try to save it it goes only for first 30% of animation. How can I make it to save the whole animation ?
Here is a bit of code( it’s long) ; MM is place where the matrices are stored (1200 of them).
import matplotlib
matplotlib.use("Agg")
from mpl_toolkits.mplot3d import axes3d
import matplotlib.animation as animation
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.cm as cm
nx = 10
ny = 10
X=np.linspace(0, Lx, nx)
Y=np.linspace(0, Ly, ny)
Writer = animation.writers['ffmpeg']
writer = Writer(fps=15, metadata=dict(artist='Me'), bitrate=1)
plt.ion()
fig = plt.figure()
im = plt.contourf(X, Y, MM[0], np.linspace(T_ok,np.max(MM[-1]),150), cmap = cm.hot)
ax = fig.add_subplot(111, projection='3d')
plt.colorbar(im)
def anime(i):
ax.cla()
im = ax.contourf(X, Y, MM[i], np.linspace(T_ok,np.max(MM[-1]),150), cmap = cm.hot)
plt.title('%5.3f'%i)
return im,
anim = animation.FuncAnimation(fig, anime)
anim.save('anime.mp4', writer=writer)EDIT : I just set frames to 10000 and it’s working, but I would like to know why. There are 1200 matrices that should be plotted.