
Recherche avancée
Médias (17)
-
Matmos - Action at a Distance
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
DJ Dolores - Oslodum 2004 (includes (cc) sample of “Oslodum” by Gilberto Gil)
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Danger Mouse & Jemini - What U Sittin’ On ? (starring Cee Lo and Tha Alkaholiks)
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Cornelius - Wataridori 2
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
The Rapture - Sister Saviour (Blackstrobe Remix)
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Chuck D with Fine Arts Militia - No Meaning No
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
Autres articles (67)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 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 (...) -
Amélioration de la version de base
13 septembre 2013Jolie sélection multiple
Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)
Sur d’autres sites (9446)
-
Executing ffmpeg command using Popen
21 septembre 2014, par dragonatorI have a strange problem trying to execute
ffmpeg
command using Popen.
I have the following piece of code, which I use for executing an external commands in Python :from subprocess import Popen, PIPE
from datetime import datetime
class Executor(object):
@classmethod
def execute(cls, command):
"""
Executing a given command and
writing into a log file in cases where errors arise.
"""
p = Popen(command, stdin=PIPE, stdout=PIPE, stderr=PIPE)
output, err = p.communicate()
if p.returncode:
with open("failed_commands.log", 'a') as log:
now = datetime.now()
log.write('{}/{}/{} , {}:{}:{}\n\n'.format(now.day, now.month,
now.year, now.hour,
now.minute,
now.second))
log.write("COMMAND:\n{}\n\n".format(" ".join(command)))
log.write("OUTPUT:\n{}\n\n".format(output.decode("utf-8")))
log.write("ERRORS:\n{}\n".format(err.decode("utf-8")))
log.write('-'*40)
log.write('\n')
return ''
if not output:
output += ' '
return outputI’ve tested it with others commands, but when I try to execute
ffmpeg
command - it fails.
I’m trying to convert some audio format to mp3 format.
Here is an example of my command :ffmpeg -i "/path/old_song.m4a" "/path/new_song.mp3"
...simple as that.When I run it in terminal it works fine, but when I try to execute it using the above function it fails.
Here is the exact error :----------------------------------------
21/9/2014 , 19:48:50
COMMAND:
ffmpeg -i "/path/old_song.m4a" "/path/new_song.mp3"
OUTPUT:
ERRORS:
ffmpeg version 2.2.3 Copyright (c) 2000-2014 the FFmpeg developers
built on Jun 9 2014 08:01:43 with gcc 4.9.0 (GCC) 20140521 (prerelease)
configuration: --prefix=/usr --disable-debug --disable-static --enable-avisynth --enable-avresample --enable-dxva2 --enable-fontconfig --enable-gnutls --enable-gpl --enable-libass --enable-libbluray --enable-libfreetype --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libv4l2 --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-pic --enable-postproc --enable-runtime-cpudetect --enable-shared --enable-swresample --enable-vdpau --enable-version3 --enable-x11grab
libavutil 52. 66.100 / 52. 66.100
libavcodec 55. 52.102 / 55. 52.102
libavformat 55. 33.100 / 55. 33.100
libavdevice 55. 10.100 / 55. 10.100
libavfilter 4. 2.100 / 4. 2.100
libavresample 1. 2. 0 / 1. 2. 0
libswscale 2. 5.102 / 2. 5.102
libswresample 0. 18.100 / 0. 18.100
libpostproc 52. 3.100 / 52. 3.100
"/path/old_song.m4a": No such file or directory
Conversion failed!
----------------------------------------...and as you can think of - the file exists.
I think there is something in passing the command to
Popen.communicate
but I don’t know exactly.Kind regards,
Teodor D.
PS : I’m passing the command toExecutor.execute as Python
list.PSS : Calling the
Executor.execute
:def process_conversion(self):
for song in self.files_to_convert:
current_format = song.rsplit('.', 1)[-1]
old_file = '"{}{}{}"'.format(self.target_dir, os.sep, song)
new_file = '"{}{}{}"'.format(self.target_dir, os.sep,
song.replace(current_format, 'mp3'))
command = ["ffmpeg", "-i", old_file, new_file]
Executor.execute(command) -
Youtube-dl convert to MP3 multi cores [on hold]
1er janvier 2017, par Top Games a-ZDo you know how to tell to youtube-dl to use all cpu cores when convert music (using ffmpeg) to mp3 ? Because it downloads the song but when it has to convert it uses just one core. Thank you.
-
FFMPEG YouTube Live Too Fast
6 avril 2017, par Liam MartensSo I am streaming video and audio to YouTube as follows
THE CONTEXT
1. First I convert a graphic GIF to an MP4 file
ffmpeg -f gif -i graphic.gif -c:v libx264 -pix_fmt yuv420p -vf scale=1280:-1 temp.mp4
2. Then I overlay a PNG with text over the MP4
ffmpeg -i temp.mp4 -i overlay.png -filter_complex "overlay=10:10" '.$graphicsPath.'/graphic.mp4
3. Then I start the stream the video and combine it with audio using following code (sources.txt is just a concat list *)
ffmpeg -f concat -i sources.txt -i music.mp3 \
-c:v libx264 -c:a aac -shortest -deinterlace \
-pix_fmt yuv420p -preset '.$encoding.' -r 30 -g 60 -b:v 2500k \
-acodec libmp3lame -ar 44100 -threads 6 -qscale 3 -b:a 712000 \
-maxrate 800k -bufsize 1400k \
-f flv rtmp://a.rtmp.youtube.com/live2/KEY4. After the stream ends, the code starts over again with a new song to mimic a 247 stream.
THE ISSUE
So the issue I am having is that it appears to be streaming too fast. It’s like the opposite of buffering issues where the buffer is way too long (as in a full song buffered by the time the first one has finished if you open the stream)
Does anyone know how I could throttle the output ? I have tried with
maxrate
andbufsize
but no real result.* sources.txt example
file ’graphic.mp4’
file ’graphic.mp4’
file ’graphic.mp4’
file ’graphic.mp4’
file ’graphic.mp4’
file ’graphic.mp4’
and so on