Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions dejavu/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,12 +133,8 @@ def fingerprint_file(self, file_path: str, song_name: str = None) -> None:
if song_hash in self.songhashes_set:
print(f"{song_name} already fingerprinted, continuing...")
else:
song_name, hashes, file_hash = Dejavu._fingerprint_worker(
file_path,
self.limit,
song_name=song_name
)
sid = self.db.insert_song(song_name, file_hash)
song_name, hashes, file_hash = Dejavu._fingerprint_worker((file_path, self.limit))
sid = self.db.insert_song(song_name, file_hash, len(hashes))

self.db.insert_hashes(sid, hashes)
self.db.set_song_fingerprinted(sid)
Expand Down
2 changes: 1 addition & 1 deletion test_dejavu.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ python dejavu.py -f ./mp3/ mp3
# away from start or end, sampling with random seed = 42, and finally
# store results in ./results and log to dejavu-test.log
python run_tests.py \
--secs 5 \
--seconds 5 \
--temp ./temp_audio \
--log-file ./results/dejavu-test.log \
--padding 8 \
Expand Down