
Recherche avancée
Médias (91)
-
Les Miserables
9 décembre 2019, par
Mis à jour : Décembre 2019
Langue : français
Type : Textuel
-
VideoHandle
8 novembre 2019, par
Mis à jour : Novembre 2019
Langue : français
Type : Video
-
Somos millones 1
21 juillet 2014, par
Mis à jour : Juin 2015
Langue : français
Type : Video
-
Un test - mauritanie
3 avril 2014, par
Mis à jour : Avril 2014
Langue : français
Type : Textuel
-
Pourquoi Obama lit il mes mails ?
4 février 2014, par
Mis à jour : Février 2014
Langue : français
-
IMG 0222
6 octobre 2013, par
Mis à jour : Octobre 2013
Langue : français
Type : Image
Autres articles (58)
-
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 (...) -
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
MediaSPIP v0.2
21 juin 2013, parMediaSPIP 0.2 is the first MediaSPIP stable release.
Its official release date is June 21, 2013 and is announced here.
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 (...)
Sur d’autres sites (7125)
-
OSError : [Errno 13] Permission denied when running python code called extract.py
26 avril 2017, par aisunshinehuiffmpeg.py :
def resize(videoName, resizedName):
if not os.path.exists(videoName):
print '%s does not exist!' % videoName
return False
# call ffmpeg and grab its stderr output
p = subprocess.Popen([ffmpeg, "-i", videoName],stderr=subprocess.PIPE)
out, err = p.communicate()
# search resolution info
if err.find('differs from') > -1:
return False
reso = re.findall(r'Video.*, ([0-9]+)x([0-9]+)', err)
if len(reso) < 1:
return False
# call ffmpeg again to resize
subprocess.call([ffmpeg, '-i', videoName, '-s', '160 x 120', resizedName])
return check(resizedName)
# check the video file is corrupted or not
def check(videoName):
if not os.path.exists(videoName):
return False
p = subprocess.Popen([ffmpeg, "-i", videoName], stderr=subprocess.PIPE)
out, err = p.communicate()
if err.find('Invalid') > -1:
return False
return Trueextract.py :
def extract(videoName, outputBase):
if not os.path.exists(videoName):
print '%s does not exist!' % videoName
return False
if check_dup(outputBase):
print '%s processed' % videoName
return True
resizedName = os.path.join(tmpDir, os.path.basename(videoName))
if not ffmpeg.resize(videoName, resizedName):
resizedName = videoName # resize failed, just use the input video
subprocess.call('%s %s | %s %s %s %s' % (dtBin, resizedName, fvBin, pcaList, codeBookList, outputBase), shell=True)
return True
def check_dup(outputBase):
"""
Check if fv of all modalities have been extracted
"""
featTypes = ['traj', 'hog', 'hof', 'mbhx', 'mbhy']
featDims = [20, 48, 54, 48, 48]
for i in range(len(featTypes)):
featName = '%s.%s.fv.txt' % (outputBase, featTypes[i])
if not os.path.isfile(featName) or not os.path.getsize(featName) > 0:
return False
# check if the length of feature can be fully divided by featDims
f = open(featName)
featLen = len(f.readline().rstrip().split())
f.close()
if featLen % (featDims[i] * 512) > 0:
return False
return Truei run the extract.py in the terminal and error occurred as follows,then add sudo and run chmod 777 -R /usr/lib/python2.7 to change the permission but it doesn`t work !
aisunshinehui@aisunshinehui : /program/dtfv/script$ sudo python extract_fv.py /home/aisunshinehui/program/dtfv/script/videolist/video.txt
/home/aisunshinehui/program/dtfv/script/output/ 1
[sudo] password for aisunshinehui:
0 /home/aisunshinehui/program/dtfv/script/videolist
Traceback (most recent call last):
File "extract_fv.py", line 63, in <module>
extract(videos[i], outputName)
File "extract_fv.py", line 27, in extract
if not ffmpeg.resize(videoName, resizedName):
File "/home/aisunshinehui/program/dtfv/script/ffmpeg.py", line 17, in resize
p = subprocess.Popen([ffmpeg, "-i", videoName], stderr=subprocess.PIPE)
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 13] Permission denied
</module>help me !
-
ffmpeg permission denied though the user has permission
12 octobre 2014, par codename_subhoI have installed ffmpeg in my server running ubuntu 14. my flask app project root is at /var/www/project/
i am able to upload files and my python scripts are able to write new files, but when i run ffmpeg in my script it gives permission denied.
Also running the below line in terminalffmpeg -i path/to/inputfile /path/to/outputfile & ps aux | grep ffmpeg
gives the user running the process is "ubuntu" which has write access to the project folder and its subfolders. As i told you other python script run by user "ubuntu" is able to create file.permission denied error happens in both cases(python script and directly in terminal)
update :
also looking at the confusion with the permissions, is there a way i can run the app from /home/ubuntu/project instead of /var/www/project. i am using mod_wsgi with apache for my flask-app. -
OSError : [errno2] no such file or directory and OSError : [Errno 12] Cannot allocate memory
30 octobre 2018, par elenaI am trying to convert video with
Apache Kafka
andFFmpeg
. I have run my program on my system, but it fails when it runs on the server. I run code I got this error :Traceback (most recent call last):
File "/home/fu/kafka/kafkaVideo/ffmpeg-python-master/ffmpeg/send.py", line 30, in <module>
subprocess.call([sys.executable, start])
File "/usr/lib/python2.7/subprocess.py", line 523, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib/python2.7/subprocess.py", line 711, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1235, in _execute_child
self.pid = os.fork()
OSError: [Errno 12] Cannot allocate memory
frame send
frame send
frame send
frame send
...
raceback (most recent call last):
File "/home/fu/kafka/kafkaVideo/ffmpeg-python-master/ffmpeg/send.py", line 30, in <module>
subprocess.call([sys.executable, start])
File "/usr/lib/python2.7/subprocess.py", line 523, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib/python2.7/subprocess.py", line 711, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1235, in _execute_child
self.pid = os.fork()
OSError: [Errno 12] Cannot allocate memory
frame send
frame send
...
Traceback (most recent call last):
File "send.py", line 107, in <module>
publish_video(video_path)
File "send.py", line 48, in publish_video
subprocess.call([sys.executable, start])
File "/usr/lib/python2.7/subprocess.py", line 523, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib/python2.7/subprocess.py", line 1392, in wait
pid, sts = _eintr_retry_call(os.waitpid, self.pid, 0)
File "/usr/lib/python2.7/subprocess.py", line 476, in _eintr_retry_call
return func(*args)``
OSError: [Errno 2] No such or directory
</module></module></module>but The third part of the error is different in different debug