I try to run a simple script in Google Colab to determine a length of a video:
!pip install moviepy
from moviepy.editor import *
# Change directory:
os.chdir(r'/content/my_data')
clip = VideoFileClip("my_video.mp4")
print(clip.duration)
However, I obtain an error:
imageio.ffmpeg.download() has been deprecated. Use 'pip install imageio-ffmpeg' instead.'
After quick search I found that imageio
needs to be downgraded by doing this:
!pip install imageio==2.4.1
So I changed the scrip to following:
!pip install moviepy
!pip install imageio==2.4.1
from moviepy.editor import *
# Change directory:
os.chdir(r'/content/my_data')
clip = VideoFileClip("my_video.mp4")
print(clip.duration)
I am still getting the same error.
Any idea how to fix it? Thank you.