worldveil / dejavu

Audio fingerprinting and recognition in Python
MIT License
6.36k stars 1.43k forks source link

BUG Report: time index to seconds is error #198

Open thesby opened 5 years ago

thesby commented 5 years ago

In __init__.py,

        nseconds = round(float(largest) / fingerprint.DEFAULT_FS *
                         fingerprint.DEFAULT_WINDOW_SIZE *
                         fingerprint.DEFAULT_OVERLAP_RATIO, 5)

should be

        nseconds = round(float(largest) / fingerprint.DEFAULT_FS *
                         fingerprint.DEFAULT_WINDOW_SIZE *
                         (1-fingerprint.DEFAULT_OVERLAP_RATIO), 5)

Because the slide is the counter of window overlap