Recherche avancée

Médias (0)

Mot : - Tags -/formulaire

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (63)

  • Demande de création d’un canal

    12 mars 2010, par

    En fonction de la configuration de la plateforme, l’utilisateur peu avoir à sa disposition deux méthodes différentes de demande de création de canal. La première est au moment de son inscription, la seconde, après son inscription en remplissant un formulaire de demande.
    Les deux manières demandent les mêmes choses fonctionnent à peu près de la même manière, le futur utilisateur doit remplir une série de champ de formulaire permettant tout d’abord aux administrateurs d’avoir des informations quant à (...)

  • MediaSPIP v0.2

    21 juin 2013, par

    MediaSPIP 0.2 est la première version de MediaSPIP stable.
    Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

  • MediaSPIP version 0.1 Beta

    16 avril 2011, par

    MediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
    Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
    Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
    Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...)

Sur d’autres sites (14018)

  • Inside WebM Technology : The VP8 Alternate Reference Frame

    15 juin 2010, par noreply@blogger.com (John Luther) — inside webm, vp8

    Since the WebM project was open-sourced just a week ago, we’ve seen blog posts and articles about its capabilities. As an open project, we welcome technical scrutiny and contributions that improve the codec. We know from our extensive testing that VP8 can match or exceed other leading codecs, but to get the best results, it helps to understand more about how the codec works. In this first of a series of blog posts, I’ll explain some of the fundamental techniques in VP8, along with examples and metrics.

    The alternative reference frame is one of the most exciting quality innovations in VP8. Let’s delve into how VP8 uses these frames to improve prediction and thereby overall video quality.

    Alternate Reference Frames in VP8

    VP8 uses three types of reference frames for inter prediction : the last frame, a "golden" frame (one frame worth of decompressed data from the arbitrarily distant past) and an alternate reference frame. Overall, this design has a much smaller memory footprint on both encoders and decoders than designs with many more reference frames. In video compression, it is very rare for more than three reference frames to provide significant quality benefit, but the undesirable increase in memory footprint from the extra frames is substantial.

    Unlike other types of reference frames used in video compression, which are displayed to the user by the decoder, the VP8 alternate reference frame is decoded normally but is never shown to the user. It is used solely as a reference to improve inter prediction for other coded frames. Because alternate reference frames are not displayed, VP8 encoders can use them to transmit any data that are helpful to compression. For example, a VP8 encoder can construct one alternate reference frame from multiple source frames, or it can create an alternate reference frame using different macroblocks from hundreds of different video frames.

    The current VP8 implementation enables two different types of usage for the alternate reference frame : noise-reduced prediction and past/future directional prediction.

    Noise-Reduced Prediction

    The alternate reference frame is transmitted and decoded similar to other frames, hence its usage does not add extra computation in decoding. The VP8 encoder however is free to use more sophisticated processing to create them in off-line encoding. One application of the alternate reference frame is for noise-reduced prediction. In this application, the VP8 encoder uses multiple input source frames to construct one reference frame through temporal or spatial noise filtering. This "noise-free" alternate reference frame is then used to improve prediction for encoding subsequent frames.

    You can make use of this feature by setting ARNR parameters in VP8 encoding, where ARNR stands for "Alternate Reference Noise Reduction." A sample two-pass encoding setting with the parameters :

    --arnr-maxframes=5 --arnr-strength=3

    enables the encoder to use "5" consecutive input source frames to produce one alternate reference frame using a filtering strength of "3". Here is an example showing the quality benefit of using this experimental "ARNR" feature on the standard test clip "Hall Monitor." (Each line on the graph represents the quality of an encoded stream on a given clip at multiple datarates. The higher points on the Y axis (PSNR) indicates the stream with the better quality.)


    The only difference between the two curves in the graph is that VP8_ARNR was produced by encodings with ARNR parameters and VP8_NO_ARNR was not. As we can see from the graph, noise reduced prediction is very helpful to compression quality when encoding noisy sources. We’ve just started to explore this idea but have already seen strong improvements on noisy input clips similar to this "Hall Monitor." We feel there’s a lot more we can do in this area.

    Improving Prediction without B Frames

    The lack of B frames in VP8 has sparked some discussion about its ability to achieve competitive compression efficiency. VP8 encoders, however, can make intelligent use of the golden reference and the alternate reference frames to compensate for this. The VP8 encoder can choose to transmit an alternate reference frame similar to a "future" frame, and encoding of subsequent frames can make use of information from the past (last frame and golden frame) and from the future (alternate reference frame). Effectively, this helps the encoder to achieve results similar to bidirectional (B frame) prediction without requiring frame reordering in the decoder. Running in two-pass encoding mode, compression can be improved in the VP8 encoder by using encoding parameters that enable lagged encoding and automatic placement of alternate reference frames :

    --auto-alt-ref=1 --lag-in-frames=16

    Used this way, the VP8 encoder can achieve improved prediction and compression efficiency without increasing the decoder’s complexity :


    In the video compression community, "Mobile and calendar" is known as a clip that benefits significantly from the usage of B frames. The graph above illustrates that the use of alternate reference frame benefits VP8 significantly without using B frames.

    Keep an eye on this blog for more posts about VP8 encoding. You can find more information on above encoding parameters or other detailed instructions to use with our VP8 encoders on our site, or join our discussion list.

    Yaowu Xu, Ph.D. is a codec engineer at Google.

  • Saving an animation using ffmpeg and matplotlib on anaconda3

    21 juin 2016, par Varsha Dyavaiah

    I am trying to create videos of NBA Action with Sportsvu data.

    I was following the steps given in this blog by Dan Vatterott :

    http://www.danvatterott.com/blog/2016/06/16/creating-videos-of-nba-action-with-sportsvu-data/?utm_campaign=Data%2BElixir&utm_medium=email&utm_source=Data_Elixir_84

    I am trying to create a animation and save it using ffmpeg and matplotlib.
    The code snippet is attached below.

    import matplotlib.animation as animation
    plt.rcParams['animation.ffmpeg_path'] = '/home/anaconda3/pkgs/ffmpeg-2.1.0-1/bin'

    fig = plt.figure(figsize=(15,7.5)) #create figure object
    ax = plt.gca() #create axis object

    draw_court([0,100,0,50]) #draw the court
    player_text = list(range(10)) #create player text vector
    player_circ = list(range(10)) #create player circle vector
    ball_circ = plt.Circle((0,0), 1.1, color=[1, 0.4, 0]) #create circle object for bal
    for i in list(range(10)): #create circle object and text object for each player
        col=['w','k'] if i<5 else ['k','w'] #color scheme
        player_circ[i] = plt.Circle((0,0), 2.2, facecolor=col[0],edgecolor='k') #player circle
        player_text[i] =   ax.text(0,0,'',color=col[1],ha='center',va='center') #player jersey # (text)

    ani = animation.FuncAnimation(fig, animate,  frames=np.arange(0,np.size(ball_xy,0)), init_func=init, blit=True, interval=5, repeat=False,\
                            save_count=0) #function for making video

    FFwriter = animation.FFMpegWriter()
    ani.save('Event_%d.mp4' % (search_id),dpi=100,writer = FFwriter,fps=25) #function for saving video
    plt.close('all') #close the plot

    When I try to save the animation ’ani’ , I get Errno 13 (Permission denied).

    ---------------------------------------------------------------------------
    PermissionError                           Traceback (most recent call last)
    in <module>()
        17
        18 FFwriter = animation.FFMpegWriter()
    ---> 19 ani.save('Event_%d.mp4' % (search_id),dpi=100,writer = FFwriter,fps=25) #function for saving video
    20 plt.close('all') #close the plot

    /home/anaconda3/lib/python3.5/site-packages/matplotlib/animation.py in save(self, filename, writer, fps, dpi, codec, bitrate, extra_args, metadata, extra_anim, savefig_kwargs)
       799         # since GUI widgets are gone. Either need to remove extra code to
       800         # allow for this non-existant use case or find a way to make it work.
    --> 801         with writer.saving(self._fig, filename, dpi):
       802             for anim in all_anim:
       803                 # Clear the initial frame

    /home/anaconda3/lib/python3.5/contextlib.py in __enter__(self)
        57     def __enter__(self):
        58         try:
    ---> 59             return next(self.gen)
        60         except StopIteration:
        61             raise RuntimeError("generator didn't yield") from None

    /home/anaconda3/lib/python3.5/site-packages/matplotlib/animation.py in saving(self, *args)
       192         '''
       193         # This particular sequence is what contextlib.contextmanager wants
    --> 194         self.setup(*args)
       195         yield
       196         self.finish()

    /home/anaconda3/lib/python3.5/site-packages/matplotlib/animation.py in setup(self, fig, outfile, dpi, *args)
       182         # Run here so that grab_frame() can write the data to a pipe. This
       183         # eliminates the need for temp files.
    --> 184         self._run()
       185
       186     @contextlib.contextmanager

    /home/anaconda3/lib/python3.5/site-packages/matplotlib/animation.py in _run(self)
       210                                       stdout=output, stderr=output,
       211                                       stdin=subprocess.PIPE,
    --> 212                                       creationflags=subprocess_creation_flags)
       213
       214     def finish(self):

    /home/anaconda3/lib/python3.5/subprocess.py in __init__(self, args, bufsize, executable, stdin, stdout, stderr, preexec_fn, close_fds, shell, cwd, env, universal_newlines, startupinfo, creationflags, restore_signals, start_new_session, pass_fds)
       948                                 c2pread, c2pwrite,
       949                                 errread, errwrite,
    --> 950                                 restore_signals, start_new_session)
       951         except:
       952             # Cleanup if the child failed starting.

    /home/anaconda3/lib/python3.5/subprocess.py in _execute_child(self, args, executable, preexec_fn, close_fds, pass_fds, cwd, env, startupinfo, creationflags, shell, p2cread, p2cwrite, c2pread, c2pwrite, errread, errwrite, restore_signals, start_new_session)
      1542                             else:
      1543                                 err_msg += ': ' + repr(orig_executable)
    -> 1544                     raise child_exception_type(errno_num, err_msg)
      1545                 raise child_exception_type(err_msg)
      1546

    PermissionError: [Errno 13] Permission denied
    </module>

    Can someone help me ? Thanks in advance.

  • In Flutter, how to get image pixel

    12 janvier 2024, par Pianone

    my code here

    &#xA;

    var response = await Dio().get(&#xA;   url,&#xA;   options: Options(responseType: ResponseType.bytes)&#xA;);&#xA;Uint8List? srcImage = Uint8List.fromList(response.data);&#xA;Uint8List? watermark = await captureWaterMark();&#xA;Image i = Image.memory(srcImage!);&#xA;//how can I get the pixel (Image i) such like 1920*1080 or just width/hight pixel&#xA;...tell me how to do...&#xA;srcImage = await addWaterMarkByFfmpegCommand(srcImage, watermark);&#xA;   final result = await ImageGallerySaver.saveImage(&#xA;      srcImage!, name: name,&#xA;   );&#xA;

    &#xA;

    i need get the pic pixel so that i can use it in ffmpeg command, it a func that add a watermark into srcImage, but cause their pixel ratio too diff to adapted watermark

    &#xA;

    i try to get pixel from ffmpeg... but i failed

    &#xA;

    /// addWaterMark by using ffmpeg Command&#xA;Future addWaterMarkByFfmpegCommand(Uint8List srcImg, Uint8List watermark) async {&#xA;  try {&#xA;    final Directory tempDir = await Directory.systemTemp.createTemp();&#xA;    final File image1File = File(&#x27;${tempDir.path}/srcImg.jpg&#x27;);&#xA;    await image1File.writeAsBytes(srcImg);&#xA;    final File image2File = File(&#x27;${tempDir.path}/watermark.png&#x27;);&#xA;    await image2File.writeAsBytes(watermark);&#xA;&#xA;    final String outputFilePath = &#x27;${tempDir.path}/output.jpg&#x27;;&#xA;    //when i get srcImage pixel, the positions in bold(iw*1) in the following commands will be replaced to make watermark adapted&#xA;    final String command =&#xA;        &#x27;-i ${image1File.path} -i ${image2File.path} -filter_complex "[1:v]scale=**iw*1**:-1[v1];[0:v][v1]overlay=10:10" -frames:v 1 $outputFilePath&#x27;;&#xA;    await FFmpegKit.execute(command);&#xA;&#xA;    final File outputFile = File(outputFilePath);&#xA;    final Uint8List outputBytes = await outputFile.readAsBytes();&#xA;    return outputBytes;&#xA;  } catch (e) {&#xA;    print(&#x27;Error executing ffmpeg command: $e&#x27;);&#xA;  }&#xA;  return null;&#xA;}&#xA;

    &#xA;

    ps : i am new to flutter and ffmpeg, plz help me, I'd appreciate, thanks alot

    &#xA;