
Recherche avancée
Médias (1)
-
Bug de détection d’ogg
22 mars 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Video
Autres articles (31)
-
Emballe médias : à quoi cela sert ?
4 février 2011, parCe plugin vise à gérer des sites de mise en ligne de documents de tous types.
Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ; -
Contribute to a better visual interface
13 avril 2011MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community. -
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...)
Sur d’autres sites (5851)
-
How to set ffmpeg for matplotlib in mac os x
4 février 2014, par AlexNoirI want to animate some plots with matplotlib. The version I have is the Enthough Canopy distribution (Version : 1.1.0.1371), running in a mac os x 10.8 (Mountain Lion). I have used the FuncAnimation routine from the animation package of matplotlib. My problem comes saving the animation. I want to save in mp4 format :
anim.save('test.mp4',fps=30)
The error I get is :
UserWarning: MovieWriter ffmpeg unavailable
warnings.warn("MovieWriter %s unavailable" % writer)So I installed ffmpeg via Macports. But I am still having the same error. Do you know how to setup matplotlib in order to recognise ffmpeg ? Do I have to change the matplotlibrc file ?
Thanks.EDIT : I have realized that I can manually put '/opt/local/bin' in the PYTHONPATH, but it does not change the PATH in Enthough Canopy. Do anyone know how to change the PATH in canopy ?
-
Error in Splitting Educational Videos into Segments Using Python (ffmpeg issue) [closed]
28 décembre 2024, par Yahia Mohamed HanbalI created a Python project to split long educational videos into smaller segments, each focused on a single question. The program uses OCR to detect text on video frames, identifies the word "Question," extracts the number following it, and splits the video whenever the number increases.


here is the video i am tring to split ((video))


Here’s an example of the program’s output :


Video loaded: 14071 frames at 60 FPS, duration: 234.52s 
Frame 480, Time 8.00s, Question: 6 
... 
Frame 12360, Time 206.00s, Question: 7 
Creating segment 1: 8.00s to 206.00s 
Error: module 'ffmpeg' has no attribute 'Error'



I’ve shared the full code in a GitHub repository for reference : Automated Video Scene Cutting.


What the Program Does


- 

- Input : A long educational video.
- Processing :

- 

- Detects text in each frame using OCR.
- Searches for the word "Question" followed by a number.
- Monitors when the number increases to identify segment boundaries.








- Output : Creates video segments corresponding to individual questions.








The Problem


The program detects the questions and timestamps correctly, but when it tries to create the segments, I encounter the following error :


Error: module 'ffmpeg' has no attribute 'Error'



What I’ve Tried


- 

- Verified the
ffmpeg-python
library is installed (pip show ffmpeg-python
confirms the installation). - Ensured the
ffmpeg
binary is accessible from the command line. - Reviewed the library documentation to ensure the correct usage of
ffmpeg
. - Tested with different video files to rule out input-specific issues.










Environment Details


- 

- OS : Windows 11
- Python Version : 3.9.13
- Key Libraries :
ffmpeg-python








If anyone has insights into resolving this issue or suggestions for alternative approaches to handle this use case, I’d greatly appreciate your help.


Thank you !


-
Small discord bot with a set of working music commands, about 6 days ago the play function completely stopped functioning (more below)
24 février 2021, par TheColoradoKidIt is a small discord python bot for my server with various features, which had included music commands until they stopped out of the blue without showing any error for the problem.
It uses FFMpeg, and youtubeDl along with pytube to gather the song and store it locally to play it, I have pip updated all of these and they are definitely on the current versions as I have made sure of this online.
Any help or insight anyone could provide would be greatly appreciated. I'm sorry if the code is convoluted in the way it's written I'm still pretty new to coding and this is one of my first proper larger projects.


If you need any information I'm happy to give what I can to help.


Here is the code for the play command :


@client.command()
async def play(ctx, *args):
 global queu
 #global autom
 if not args:
 voice = get(client.voice_clients, guild=ctx.guild)
 if not voice.is_playing():
 server = ctx.message.guild
 voice_channel = server.voice_client
 if queu:
 async with ctx.typing():
 player = await YTDLSource.from_url(queu[0], loop=client.loop)
 voice_channel.play(player, after=lambda e: print('Player error: %s' % e) if e else None)

 await ctx.send('**Now playing:** {}'.format(player.title))
 del(queu[0])
 # while autom == True:
 # try:
 # a = client.get_command('auto')
 # await ctx.invoke(a)
 # except:
 # print('')
 elif not queu:
 await ctx.send("You can't play if there isn't anything in the queue\nIf auto mode was on it has now been disabled, to use it gain please add to the queue and run ``;auto on``")
 autom = False
 if args:
 global gueu
 search_keywords = ""
 print(args)
 for word in args:
 search_keywords += word
 search_keywords += '+'
 link = "https://www.youtube.com/results?search_query="
 link += search_keywords
 #print(link)
 html = urllib.request.urlopen(link)
 video_ids = re.findall(r"watch\?v=(\S{11})", html.read().decode())
 url = ("https://www.youtube.com/watch?v=" + video_ids[0])
 #print(url)
 queu.append(url)
 #print(queu)
 await ctx.send("``{}`` added to queue!\n If the song doesn't start please either let the current song end and run ``;play``/``;next`` again or run ``;next`` to play now".format(url))
 try:
 p = client.get_command('play')
 await ctx.invoke(p)
 except:
 print('failed')