
Recherche avancée
Médias (1)
-
La conservation du net art au musée. Les stratégies à l’œuvre
26 mai 2011
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (99)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...) -
Support audio et vidéo HTML5
10 avril 2011MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)
Sur d’autres sites (8556)
-
dcaenc : Reverse data layout to prevent data copies during Huffman encoding introduction
6 janvier 2017, par Daniil Cherednik -
ffmpeg –i /data/1.mp4 /data/2.mp4 Unable to find a suitable output format for '–i' [duplicate]
17 octobre 2016, par D.jiaThis question already has an answer here :
I have installed ffmpeg ,why doesn’t it work when I enter
ffmpeg –i /data/1.mp4 /data/2.mp4 ??
Could someone help me to solve it !
-
attempting to save FuncAnimation changes the animation
25 mars 2024, par pibionI am attempting to create and save an animation of a time-varying vector field using matplotlib's FuncAnimation. When I run the animation without attempting to save it, it updates smoothly as expected. However, when I try to save the animation, the vectors increase in length and the animation only appears to update a few times. I've been able to record the screen to get a video file, but I'd like to understand how to save the animation to a video in python.


Here is the code to create the vector field animation. I ran this in a local jupyter notebook using python 3.9.12 on Windows.


%matplotlib notebook
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.animation as animation

x_min, x_max = -20, 20
y_min, y_max = 0, 25
wire_x = -4
wire_y = 17

# Define the vector field function (example: rotating vector field)
def vector_field(x, y, t):
 x = x - wire_x
 y = y - wire_y
 r = np.sin(t) / (x**2 + y**2)
 u = -r * y
 v = r * x
 return (u, v)

# Define grid
x = np.linspace(x_min, x_max, 20)
y = np.linspace(y_min, y_max, 20)
X, Y = np.meshgrid(x, y)

# Create animation
fig, ax = plt.subplots(1,1)
ax.set_aspect('equal')
ax.set_xlim(x_min, x_max)
ax.set_ylim(y_min, y_max)
ax.set_xlabel('X (m)')
ax.set_ylabel('Y (m)')

u, v = vector_field(X, Y, 1)

quiver = ax.quiver(X, Y, u, v)

time_arr = np.linspace(0,20,200)

plt.show()

def update_quiver(num):
 t = num * 0.1 # Time step
 u, v = vector_field(X, Y, t)
 quiver.set_UVC(u, v)

ani = animation.FuncAnimation(fig, update_quiver, frames=200, interval=50, repeat=False)



This produces an animation whose vectors smoothly vary in length on my computer.


However, when I try to save the animation by adding the lines


writervideo = animation.FFMpegWriter(fps=60) 
ani.save('field_leftWire.mp4', writer=writervideo) 



then the animation changes - the vectors are much longer and it appears to only update a few times throughout the animation.


I'll also note that I had to install ffmpeg and restart my computer as outlined in Installation of FFMPEG for Python in WIndows to get the last two lines to run without error.