akamhy / videohash

Near Duplicate Video Detection (Perceptual Video Hashing) - Get a 64-bit comparable hash-value for any video.
https://pypi.org/project/videohash
MIT License
264 stars 41 forks source link

add a duration attribute to the videohash objects #67

Closed akamhy closed 2 years ago

akamhy commented 2 years ago
akamhy commented 2 years ago

Now that we support frame_interval ( see #68 ) can't anymore depend on counting the frames.

Instead use the following

akamhy at device in ~/Videos
$ time ffmpeg -i  video.webm  2>&1 | grep "Duration"
  Duration: 00:05:02.28, start: 0.000000, bitrate: 4855 kb/s

real    0m0.089s
user    0m0.064s
sys 0m0.029s

akamhy at device in ~/Videos
$ time ffmpeg -i  video.webm  2>&1 | grep "Duration"
  Duration: 00:05:02.28, start: 0.000000, bitrate: 4855 kb/s

real    0m0.090s
user    0m0.064s
sys 0m0.031s

akamhy at device in ~/Videos