Recherche avancée

Médias (1)

Mot : - Tags -/bug

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 (5280)

  • checkasm : added additional dstW tests for hscale

    26 mai 2022, par Swinney, Jonathan
    checkasm : added additional dstW tests for hscale
    

    Signed-off-by : Jonathan Swinney <jswinney@amazon.com>
    Signed-off-by : Martin Storsjö <martin@martin.st>

    • [DH] tests/checkasm/sw_scale.c
  • Is there a way to use youtube-dl in async

    8 octobre 2024, par Stam Kaly

    I have an application where I use zmq with asyncio to communicate with the clients who have the ability to download a video with youtube-dl to the server. I tried adding await to youtube_dl's download function but it gave me an error since it was not a coroutine. My code right now is simply looking like this :

    &#xA;&#xA;

    import asyncio&#xA;import youtube_dl&#xA;&#xA;&#xA;async def networking_stuff():&#xA;    download = True&#xA;    while True:&#xA;        if download:&#xA;            print("Received a request for download")&#xA;            await youtube_to_mp3("https://www.youtube.com/watch?v=u9WgtlgGAgs")&#xA;            download = False&#xA;        print("Working..")&#xA;        await asyncio.sleep(2)&#xA;&#xA;&#xA;async def youtube_to_mp3(url):&#xA;    ydl_opts = {&#xA;        &#x27;format&#x27;: &#x27;bestaudio/best&#x27;,&#xA;        &#x27;postprocessors&#x27;: [{&#xA;            &#x27;key&#x27;: &#x27;FFmpegExtractAudio&#x27;,&#xA;            &#x27;preferredcodec&#x27;: &#x27;mp3&#x27;,&#xA;            &#x27;preferredquality&#x27;: &#x27;192&#x27;,&#xA;        }]&#xA;    }&#xA;&#xA;    with youtube_dl.YoutubeDL(ydl_opts) as ydl:&#xA;        ydl.download([url])&#xA;&#xA;&#xA;loop = asyncio.get_event_loop()&#xA;loop.create_task(networking_stuff())&#xA;loop.run_forever()&#xA;

    &#xA;&#xA;

    which gives the following output :

    &#xA;&#xA;

    Received a request for download&#xA;[youtube] u9WgtlgGAgs: Downloading webpage&#xA;[youtube] u9WgtlgGAgs: Downloading video info webpage&#xA;[youtube] u9WgtlgGAgs: Extracting video information&#xA;[youtube] u9WgtlgGAgs: Downloading MPD manifest&#xA;[download] Destination: The Cardigans - My Favourite Game “Stone Version”-u9WgtlgGAgs.webm&#xA;[download] 100% of 4.20MiB in 00:03&#xA;[ffmpeg] Destination: The Cardigans - My Favourite Game “Stone Version”-u9WgtlgGAgs.mp3&#xA;Deleting original file The Cardigans - My Favourite Game “Stone Version”-u9WgtlgGAgs.webm (pass -k to keep)&#xA;Working..&#xA;Working..&#xA;....&#xA;Working..&#xA;Working..&#xA;

    &#xA;&#xA;

    whereas I would expect the Working.. message to be printed in between youtube-dl's messages as well. Am I missing something here or is this impossible with async/await ? Is ffmpeg blocking ? If so, can I run the download in async without converting to mp3 or is using threads the only way ?

    &#xA;

  • Convert byte array to frames [closed]

    4 juin 2021, par karen.nik98

    I have received an mp4 video via HTTP and save it all on a byte array. Now I want to get frames from that byte array. How can I do that ?

    &#xA;

    Video is sent with curl, via this command.

    &#xA;

    curl --location --request POST &#x27;0.0.0.0:5007/check&#x27; --form &#x27;video=@"/home/user/Downloads/test/test.mp4"&#x27;&#xA;

    &#xA;