Recherche avancée

Médias (91)

Autres articles (101)

  • Multilang : améliorer l’interface pour les blocs multilingues

    18 février 2011, par

    Multilang est un plugin supplémentaire qui n’est pas activé par défaut lors de l’initialisation de MediaSPIP.
    Après son activation, une préconfiguration est mise en place automatiquement par MediaSPIP init permettant à la nouvelle fonctionnalité d’être automatiquement opérationnelle. Il n’est donc pas obligatoire de passer par une étape de configuration pour cela.

  • L’agrémenter visuellement

    10 avril 2011

    MediaSPIP est basé sur un système de thèmes et de squelettes. Les squelettes définissent le placement des informations dans la page, définissant un usage spécifique de la plateforme, et les thèmes l’habillage graphique général.
    Chacun peut proposer un nouveau thème graphique ou un squelette et le mettre à disposition de la communauté.

  • Possibilité de déploiement en ferme

    12 avril 2011, par

    MediaSPIP peut être installé comme une ferme, avec un seul "noyau" hébergé sur un serveur dédié et utilisé par une multitude de sites différents.
    Cela permet, par exemple : de pouvoir partager les frais de mise en œuvre entre plusieurs projets / individus ; de pouvoir déployer rapidement une multitude de sites uniques ; d’éviter d’avoir à mettre l’ensemble des créations dans un fourre-tout numérique comme c’est le cas pour les grandes plate-formes tout public disséminées sur le (...)

Sur d’autres sites (7421)

  • Why PyAudio doesn't read 'mp3' ?

    22 octobre 2020, par freshITmeat

    I tried to read file that I give with absolute path.
When I run my code first that I see is this message :

    


    D:\prog\datascience\anaconda\lib\site-packages\pydub\utils.py:170: RuntimeWarning: Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work
  warn("Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work", RuntimeWarning)


    


    I tried this :

    


    PATH_TO_FFMPEG = 'D:\\prog\\ffmpeg-win-2.2.2\\ffmpeg.exe'
pydub.AudioSegment.converter = r'D:\\prog\\ffmpeg-win-2.2.2\\ffmpeg.exe'


    


    And I separately installed ffmpeg with pip. But it didn't help.
When I try this :

    


    raw_sound = pydub.AudioSegment.from_mp3(file=track_path)


    


    where track_path is correct absolute path generated automatically.
So I got this this error :

    


    Traceback (most recent call last):&#xA;  File "D:\prog\PyCharm Community Edition 2020.2.2\plugins\python-ce\helpers\pydev\pydevd.py", line 1448, in _exec&#xA;    pydev_imports.execfile(file, globals, locals)  # execute the script&#xA;  File "D:\prog\PyCharm Community Edition 2020.2.2\plugins\python-ce\helpers\pydev\_pydev_imps\_pydev_execfile.py", line 18, in execfile&#xA;    exec(compile(contents&#x2B;"\n", file, &#x27;exec&#x27;), glob, loc)&#xA;  File "D:/testtask2/test_task/testtask/get_mffc.py", line 165, in <module>&#xA;    slice_all_in_a_dir(&#x27;May 27 2020 LNC/Hydrophone 1/raw_records&#x27;)&#xA;  File "D:/testtask2/test_task/testtask/get_mffc.py", line 70, in slice_all_in_a_dir&#xA;    slice_samples(track_path= [file],&#xA;  File "D:/testtask2/test_task/testtask/get_mffc.py", line 48, in slice_samples&#xA;    raw_sound = pydub.AudioSegment.from_mp3(file=track_path)&#xA;  File "D:\prog\datascience\anaconda\lib\site-packages\pydub\audio_segment.py", line 738, in from_mp3&#xA;    return cls.from_file(file, &#x27;mp3&#x27;, parameters=parameters)&#xA;  File "D:\prog\datascience\anaconda\lib\site-packages\pydub\audio_segment.py", line 680, in from_file&#xA;    stdin_data = file.read()&#xA;AttributeError: &#x27;list&#x27; object has no attribute &#x27;read&#x27;&#xA;python-BaseException&#xA;</module>

    &#xA;

  • How to combine/concatenate videos stored in AWS S3 bucket based on title of the file name

    9 juin 2020, par orangecube

    I am using a service that allows me to record videos that get automatically pushed to a folder (submissions) in an S3 bucket. There are multiple videos however they need to be grouped together and concatenated so the output is one video per group.

    &#xA;&#xA;

    So, basically, any tips on how I can take videos based on the title and stitch them together ?

    &#xA;&#xA;

    Example :

    &#xA;&#xA;

    Submissions folder will have :

    &#xA;&#xA;

    a-100-2.mp4&#xA;a-200-6.mp4&#xA;b-123-5.mp4&#xA;

    &#xA;&#xA;

    Expected output in processed folder :

    &#xA;&#xA;

    a.mp4     - (both &#x27;a&#x27; videos get stitched together)&#xA;b.mp4     - (only &#x27;b&#x27; gets sent over since there is only one video.)&#xA;

    &#xA;&#xA;

    Thanks in advance !

    &#xA;&#xA;

    Edit : Some additional and detailed information below if it helps.

    &#xA;&#xA;

    The files will be labeled with :&#xA;name-location-video_token-stream_token.mp4

    &#xA;&#xA;

    Need help creating a script or process that will concatenate the videos using the procedure outlined below :

    &#xA;&#xA;

    Processing rules (back end) :

    &#xA;&#xA;

      &#xA;
    1. Check if videos have same video_token in ‘submissions folder’. If so, keep the newest one and delete old ones.

    2. &#xA;

    3. Take all videos in ‘submissions folder’ with same name and location in title and concatenate the videos. Save output video to a new folder in the bucket labeled as the location for the folder name. &#xA;Output file name : &#xA;name-location-year.mp4.

    4. &#xA;

    &#xA;&#xA;

    EXAMPLE :

    &#xA;&#xA;

    Submissions folder :&#xA;joey-toronto-001-354.mp4

    &#xA;&#xA;

    joey-toronto-001-241.mp4 - this will be deleted

    &#xA;&#xA;

    joey-toronto-103-452.mp4

    &#xA;&#xA;

    alex-montreal-352-232.mp4

    &#xA;&#xA;

    alex-montreal-452-223.mp4

    &#xA;&#xA;

    Resulting output :

    &#xA;&#xA;

    Toronto folder :

    &#xA;&#xA;

    Joey-toronto-2020.mp4

    &#xA;&#xA;

    Montreal folder :

    &#xA;&#xA;

    Alex-montreal-2020.mp4

    &#xA;

  • MobileFFMPEG Output file #0 does not contain any stream

    30 septembre 2020, par Alhaj

    I am using implementation 'com.arthenica:mobile-ffmpeg-full:4.4'

    &#xA;

    I just want o crop audio file to 10 second to 20 second

    &#xA;

    '''&#xA;fun cropAudio(input :String)

    &#xA;

        val newFileName = UUID.randomUUID().toString()&#xA;&#xA;    val location: String = getBatchDirectoryName()!!&#xA;&#xA;    val output: String = location &#x2B; "/" &#x2B; newFileName &#x2B; ".mp3"&#xA;&#xA;    val temp=" -i $input -ss 60 -to 70 $output"&#xA;&#xA;    Log.e("alhaj", " a $s")&#xA;&#xA;    FFmpeg.execute(temp, object : ExecuteCallback {&#xA;&#xA;        fun onSuccess(message: String?) {&#xA;            uploadOnFirebase(output, title)&#xA;            mediaPlayer.stop()&#xA;            Log.e("alhaj", message!!)&#xA;        }&#xA;&#xA;        override fun apply(executionId: kotlin.Long, returnCode: Int) {&#xA;            if (returnCode == RETURN_CODE_SUCCESS) {&#xA;                Log.i("alhaj", "Async command execution completed successfully.");&#xA;            } else if (returnCode == RETURN_CODE_CANCEL) {&#xA;                Log.i("alhaj", "Async command execution cancelled by user.");&#xA;            } else {&#xA;                Log.i("alhaj", String.format("Async command execution failed with rc=%d.", returnCode));&#xA;            }&#xA;        }&#xA;    }.toString())&#xA;}&#xA;

    &#xA;

    '''

    &#xA;

    but i am getting error

    &#xA;

    '''

    &#xA;

    2020-09-30 03:13:41.079 10300-10410/com.example.touchmeadmin I/mobile-ffmpeg : Output #0, mp3, to ' -i /storage/emulated/0/AJ backup/songs/Maroon 5 - Memories (Official Video) ( 256kbps cbr ).mp3 -ss 60 -to 70 /storage/emulated/0/Android/data/com.example.touchmeadmin/files/Music/830350fd-5218-4ee0-bd99-0dd50b802930.mp3' :&#xA;2020-09-30 03:13:41.079 10300-10410/com.example.touchmeadmin E/mobile-ffmpeg : Output file #0 does not contain any stream

    &#xA;

    '''

    &#xA;