Recherche avancée

Médias (1)

Mot : - Tags -/ogg

Autres articles (60)

  • Gestion générale des documents

    13 mai 2011, par

    MédiaSPIP ne modifie jamais le document original mis en ligne.
    Pour chaque document mis en ligne il effectue deux opérations successives : la création d’une version supplémentaire qui peut être facilement consultée en ligne tout en laissant l’original téléchargeable dans le cas où le document original ne peut être lu dans un navigateur Internet ; la récupération des métadonnées du document original pour illustrer textuellement le fichier ;
    Les tableaux ci-dessous expliquent ce que peut faire MédiaSPIP (...)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

Sur d’autres sites (7754)

  • Error with LocalAudioFile(file) returns OSError : [Errno 2] No such file or directory

    5 mars 2016, par beriukay

    Much like the question here http://developer.echonest.com/forums/thread/3843#reply, I am having the following error :

    File
    "/usr/local/lib/python2.7/dist-packages/echonest/remix/audio.py", line
    944, in init
    sampleRate=sampleRate, numChannels=numChannels) File "/usr/local/lib/python2.7/dist-packages/echonest/remix/audio.py", line
    403, in init
    self.load() File "/usr/local/lib/python2.7/dist-packages/echonest/remix/audio.py", line
    421, in load
    numChannels=self.numChannels, sampleRate=self.sampleRate, verbose=self.verbose) File
    "/usr/local/lib/python2.7/dist-packages/echonest/remix/support/ffmpeg.py",
    line 91, in ffmpeg
    close_fds=(not win) File "/usr/lib/python2.7/subprocess.py", line 710, in init
    errread, errwrite) File "/usr/lib/python2.7/subprocess.py", line 1327, in _execute_child
    raise child_exception OSError : [Errno 2] No such file or directory

    I checked input and output file permissions, made sure that both files and all related file paths existed, and that I have all the relevant python tools installed. The first clue is that Subprocess.py is having trouble. Looking at ffmpeg.py on line 88, I started playing around with the Popen function call to see how and why it was misbehaving.

    Solution :

    After messing around with the ffmpeg.py file, I piped the input to the shell (shell=True instead of shell=False), which raised the following error :

    check raise Run timeError(ffmpeg_install_instructions) RuntimeError: en-ffmpeg not found! Please make sure ffmpeg is installed and create a link as follows: sudo ln -s which ffmpeg /usr/local/bin/en-ffmpeg Alternatively, import echonest.remix.support.ffmpeg and modify ffmpeg.FFMPEG to name the appropriate binary.

    So, to finalize the solution, you need to get the binary from https://ffmpeg.org/download.html#build-linux, which in Ubuntu 14.04 means you just need to :

    sudo add-apt-repository ppa:mc3man/trusty-media
    sudo apt-get update && sudo apt-get upgrade
    sudo apt-get install ffmpeg
    sudo ln -s `which ffmpeg` /usr/local/bin/en-ffmpeg

    That should clear this problem right up.

  • FFmpeg output video file much smaller than uncompressed input audio file, using option to preserve original audio quality

    17 mars 2021, par Jan

    I attempt to create a video slideshow from a number of image files and an audio file in 2 steps :

    


      

    1. Create a temporary video file from a sequence of image files
    2. 


    3. Add an audio file to the temporary video file with a delay of 5 seconds
    4. 


    


    The audio file is an uncompressed stereo wav file, encoded with a sample rate of 44100 Hz and a bit depth of 32 bits, with a size of 40.1 MB. To preserve the lossless quality of the input audio file I use the option -c:a aac -b:a 192k as per Slideshow Wiki. However, the final output video file has a size of only 4.49 MB.

    


    How can the output video file be about 10 times smaller than the input audio file and still preserve the original lossless quality ?

    


    My code :

    


    ffmpeg -f concat -i slide-sequence.txt -c:v libx264 -r 30 -filter_complex format=yuv420p temp.mp4
ffmpeg -i temp.mp4 -i audio.wav -af "adelay=5000|5000" -c:v copy -c:a aac -b:a 192k out.mp4


    


  • File contains data in an unknown format. (m4a load from librosa)

    2 août 2022, par Moriyama Aiko

    So I am currently working on a DNN that takes in m4a files. I have ffmpeg, it creates a few batches and then dies on this error :

    


    Traceback (most recent call last):&#xA;  File "/users/work/s163838/./main.py", line 126, in <module>&#xA;    &#xA;  File "/users/work/s163838/./main.py", line 96, in main&#xA;    print("e")&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 521, in __next__&#xA;    data = self._next_data()&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 1203, in _next_data&#xA;    return self._process_data(data)&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/utils/data/dataloader.py", line 1229, in _process_data&#xA;    data.reraise()&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/_utils.py", line 425, in reraise&#xA;    raise self.exc_type(msg)&#xA;EOFError: Caught EOFError in DataLoader worker process 0.&#xA;Original Traceback (most recent call last):&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/librosa/core/audio.py", line 164, in load&#xA;    y, sr_native = __soundfile_load(path, offset, duration, dtype)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/librosa/core/audio.py", line 195, in __soundfile_load&#xA;    context = sf.SoundFile(path)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/soundfile.py", line 629, in __init__&#xA;    self._file = self._open(file, mode_int, closefd)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/soundfile.py", line 1183, in _open&#xA;    _error_check(_snd.sf_error(file_ptr),&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/soundfile.py", line 1357, in _error_check&#xA;    raise RuntimeError(prefix &#x2B; _ffi.string(err_str).decode(&#x27;utf-8&#x27;, &#x27;replace&#x27;))&#xA;RuntimeError: Error opening &#x27;vox2/dev/aac/id08194/QnBYPze-x9A/00079.m4a&#x27;: File contains data in an unknown format.&#xA;&#xA;During handling of the above exception, another exception occurred:&#xA;&#xA;Traceback (most recent call last):&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/utils/data/_utils/worker.py", line 287, in _worker_loop&#xA;    data = fetcher.fetch(index)&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch&#xA;    data = [self.dataset[idx] for idx in possibly_batched_index]&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/site-packages/torch/utils/data/_utils/fetch.py", line 44, in <listcomp>&#xA;    data = [self.dataset[idx] for idx in possibly_batched_index]&#xA;  File "/users/work/s163838/vox_celeb_loader.py", line 53, in __getitem__&#xA;    load(speaker2utt1, self.num_samples)&#xA;  File "/users/work/s163838/vox_celeb_loader.py", line 13, in load&#xA;    wav, sr = librosa.load(path, sr=16000)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/librosa/util/decorators.py", line 88, in inner_f&#xA;    return f(*args, **kwargs)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/librosa/core/audio.py", line 170, in load&#xA;    y, sr_native = __audioread_load(path, offset, duration, dtype)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/librosa/core/audio.py", line 226, in __audioread_load&#xA;    reader = audioread.audio_open(path)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/audioread/__init__.py", line 111, in audio_open&#xA;    return BackendClass(path)&#xA;  File "/users/kdm/s163838/.local/lib/python3.9/site-packages/audioread/rawread.py", line 65, in __init__&#xA;    self._file = aifc.open(self._fh)&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/aifc.py", line 917, in open&#xA;    return Aifc_read(f)&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/aifc.py", line 358, in __init__&#xA;    self.initfp(f)&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/aifc.py", line 314, in initfp&#xA;    chunk = Chunk(file)&#xA;  File "/apl/tryton/python/3.9.5/lib/python3.9/chunk.py", line 63, in __init__&#xA;    raise EOFError&#xA;EOFError&#xA;&#xA;</listcomp></module>

    &#xA;

    I am using this command

    &#xA;

        wav, sr = librosa.load(path, sr=16000)&#xA;

    &#xA;

    is it just a broken file ? How do I skip such then ? Or is it something about loading a m4a file even with ffmpeg and the desired output when tested on a single m4a file ?

    &#xA;