Recherche avancée

Médias (0)

Mot : - Tags -/performance

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

Autres articles (64)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accé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 (...)

  • XMP PHP

    13 mai 2011, par

    Dixit Wikipedia, XMP signifie :
    Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
    Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
    XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)

Sur d’autres sites (6581)

  • AttributeError : module 'ffmpeg' has no attribute 'load'

    23 avril 2023, par az-purplepen

    I'm having difficulty with ffmpeg. I've installed it properly (I think) but still get AttributeErrors.

    


    I used the online guide (https://ffmpeg.org/download.html), and doing pip install ffmpeg-python instead of pip install ffmpeg. I've verified the installation with pip show. I've also made sure to not name my files ffmpeg.py.

    


    However, when I try running the following commands in terminal, I get an Attribute Error. Any tips ? I've seen this question pop up before, but none of the tips have worked.

    


    >>> import ffmpeg&#xA;>>> ffmpeg.load(&#x27;cover.wav&#x27;)&#xA;Traceback (most recent call last):&#xA;  File "<stdin>", line 1, in <module>&#xA;AttributeError: module &#x27;ffmpeg&#x27; has no attribute &#x27;load&#xA;</module></stdin>

    &#xA;

  • TypeError at /api/v1/file/86370b91-8e25-4833-bbc6-a4b833363893/ 'module' object is not callable

    16 avril 2023, par Olyx

    Please help me, I'm writing a patch request that should change the video resolution, but I can't get the file back from celery&#xA;views.py

    &#xA;

    def patch(self, request, id = None):&#xA;    file = File.objects.get(id = id)&#xA;    width =  request.data.get(&#x27;width&#x27;)&#xA;    height = request.data.get(&#x27;height&#x27;)&#xA;    file.width = width&#xA;    file.height = height &#xA;   &#xA;    file.video = change_video_extension.delay(file.video.path, width, height).get()&#xA;    file.save()&#xA;    return Response({&#x27;width&#x27;:width, &#x27;height&#x27;:height})&#xA;

    &#xA;

    tasks.py

    &#xA;

    import os&#xA;from demo.celery import app&#xA;&#xA;@app.task(name = "change_video_extension")&#xA;def change_video_extension(input_file, width, height):&#xA;    output_file = "abc123.mp4"&#xA;    os.system(f"ffmpeg -i {input_file} -s {width}x{height} {output_file}")&#xA;    return output_file&#xA;

    &#xA;

    TypeError

    &#xA;

    TypeError at /api/v1/file/86370b91-8e25-4833-bbc6-a4b833363893/&#xA;'module' object is not callable&#xA;Request Method : PATCH&#xA;Request URL : http://127.0.0.1:8000/api/v1/file/86370b91-8e25-4833-bbc6-a4b833363893/&#xA;Django Version : 4.2&#xA;Exception Type : TypeError&#xA;Exception Value :
    &#xA;'module' object is not callable

    &#xA;

  • how to write subcommand to FFPLAY during playback using subprocess module ?

    4 mars 2023, par ChienMouille

    I'm trying to pause a video playback started with FFPLAY through a python subprocess. You can do this manually by pressing the "p" key on the keyboard while the video is playing. I'd like to emulate this behavior through a python call.

    &#xA;

    I'm now sending a "p" string, encoded as bytes, through the stdin of the Popen call. The video starts and I can pause it with the keyboard but the communicate command doesn't seem to do anything.

    &#xA;

    import subprocess&#xA;import time&#xA;&#xA;proc = subprocess.Popen([&#x27;ffplay&#x27;, &#x27;PATH_TO_&#x27;],&#xA;                        stdin=subprocess.PIPE,&#xA;                        stdout=subprocess.PIPE,&#xA;                        )&#xA;time.sleep(2) # just waiting to make sure playback has started&#xA;proc.communicate(input="p".encode())[0]&#xA;&#xA;

    &#xA;

    Thanks in advance !

    &#xA;