Replies: 1 comment
-
I am not super familiar with ffmpeg, so I can't necessarily help you out with that part, but I can help you understand how to use motion within the frame to detect new scenes using PySceneDetect. Note that all the motion detection in PySceneDetect is slated for an upcoming release (0.6.1), but you can download that branch and install it now if you want (this is how I tested my examples below). One thing to clarify before proceeding is what we mean by motion. There are two main ways motion within video is used for scene detection:
PySceneDetect can help with the second of these much more than the first. If you are interested in the first type of detection, might I suggest a different library by @Breakthrough instead, DVR-Scan. Alright, now on to how to use motion detection in PySceneDetect. The Doing a bit of testing on my end with the goldeneye video we use for our built-in tests, I found that using |
Beta Was this translation helpful? Give feedback.
-
In video.stats.csv, how do we make use of the data columns to identify motions? Is it possible to do so?
Currently I have ffmpeg filtering i frames for scene score and converting the output into csv format string which is then fed into python dataframe for analysis. I wonder if it's possible to do similar thing with video.stats.csv. If so, please kindly advise or give some sample code.
My experience with ffmpeg's scene scores is that there seems to be scores every 4 seconds and these scores are well above the other scores associated with the remaining frames. Currently I take thse i-frame scores into 2 approaches: 1) detect changes in score and tagging only changes larger than a threshold, and 2) perform percentile analysis on 2-minute video and check if p95% is larger than a threshold and tagging frames with scores above p50%. I am still struggling to understand its behavior. I don't think it will work or stable enough.
Beta Was this translation helpful? Give feedback.
All reactions