
Recherche avancée
Autres articles (48)
-
La file d’attente de SPIPmotion
28 novembre 2010, parUne file d’attente stockée dans la base de donnée
Lors de son installation, SPIPmotion crée une nouvelle table dans la base de donnée intitulée spip_spipmotion_attentes.
Cette nouvelle table est constituée des champs suivants : id_spipmotion_attente, l’identifiant numérique unique de la tâche à traiter ; id_document, l’identifiant numérique du document original à encoder ; id_objet l’identifiant unique de l’objet auquel le document encodé devra être attaché automatiquement ; objet, le type d’objet auquel (...) -
Mise à disposition des fichiers
14 avril 2011, parPar défaut, lors de son initialisation, MediaSPIP ne permet pas aux visiteurs de télécharger les fichiers qu’ils soient originaux ou le résultat de leur transformation ou encodage. Il permet uniquement de les visualiser.
Cependant, il est possible et facile d’autoriser les visiteurs à avoir accès à ces documents et ce sous différentes formes.
Tout cela se passe dans la page de configuration du squelette. Il vous faut aller dans l’espace d’administration du canal, et choisir dans la navigation (...) -
La sauvegarde automatique de canaux SPIP
1er avril 2010, parDans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)
Sur d’autres sites (4375)
-
Python script than run another python script, ffmpeg2vmaf
16 mai 2018, par AsusioI want to build a little API to use ffmpeg2vmaf to analyze videos that are made for the video streaming (DASH, HLS).
I’m on Linux Ubuntu 16.04, I’m using python 3.
My API can now concatenate the files into an MP4 file. To do it I’m using the library
subprocess
and the commandcat
.But when I want to use ffmpeg2vmaf it can’t find a library that ffmpeg2vmaf use.
This is how I do :
try:
os.chdir("/home/USERNAME/VMAF/vmaf/")
output_cmd = subprocess.check_output(["sudo ./ffmpeg2vmaf WIDTH HEIGHT \
'/home/alexis/video/ref.mp4' '/home/alexis/video/dist.mp4'\
>> '/home/alexis/analyze/analyze.txt'"], shell = True)
except subprocess.CalledProcessError:
print("Error")The error is :
Traceback (most recent call last):
File "./ffmpeg2vmaf", line 8, in <module>
from vmaf.config import VmafConfig, DisplayConfig
ImportError: No module named vmaf.config
</module>But if I use the same command without python, in the terminal, it works.
I have try to put my API in the same folder as "ffmpeg2vmaf" but it still doesn’t work.
Thank you by advance
-
Correcting the variable name in an ffmpeg subtitle script
21 juin 2017, par Steven FoongI have 175 mp4 video files and subtitle files with the extension .ass. Unfortunately, my smart TV is not able to read those subtitles. I plan to burn (hardcode) the subtitles into the video.
I use this command :
ffmpeg -i orgvideo.mp4 -vf subtitles="subtitle.ass" newvideo.mp4 <br />
It works. So I plan to use a
bash
script to automate the process.Everything in the script is working but the
ffmpeg
command line isn’t able to retrieve the subtitle variable.After googling around, I found that my file name has special character and space, that causes my script to fail. If the video file name and the subtitle file is simple, then the script should be no problem.
This is my script :
for f in *.mp4
do
new="${f%%.mp4} (CHT).mp4"
subtitle="${f%%.mp4}.chi.ass"
< /dev/null ffmpeg -i "$f" -vf subtitles="$subtitle" "$new"
doneThe
ffmpeg
line is having problems reading the subtitle file variable. Can anyone help ? -
Powershell Script Exits Handbrake CLI
23 décembre 2014, par Arnav AttriWith the help of google, I workaround a Powershell script for handbrake automation. Now, the issue is when the source folder is empty the Powershell script exits.
Here’s the scenario :
- I downloaded someone files - automated via RSS.
- They are placed in source folder.
- Powershell script works and encoding starts and successfully gets over.
- Now, when the encode is completed and in case of new download/file doesn’t arrive in the source folder, the script exits.
Code is in PasteBin which has more comments but should be easy to infer what the script does
$inputpath = "I:\S"
$outputpath = "I:\E"
$movies = ls $inputpath
foreach($movie in $movies){
$name = $movie.basename
if(!(test-path -path "$outputpath\$name.mkv")){
C:\"Program Files"\handbrake\HandBrakeCLI.exe -i "$inputpath\$movie" -o "$outputpath\$name.mkv" `
-e x264 -b 1000 -2 -T -a 1,1 -E mp3 -B 112 --mixdown stereo -f mkv --detelecine --decomb `
--loose-anamorphic -m -x rc-lookahead=30:ref=4:bframes=3:me=umh:subme=9:analyse=none:deblock=1:0:0:8x8dct=1
}
}