-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
added basic revive functionality. doesn't detect dead items automatically yet though. #20
base: master
Are you sure you want to change the base?
added basic revive functionality. doesn't detect dead items automatically yet though. #20
Conversation
…ist/album artist, album, track title and track number in the library and replaces selected item(s) with best bitrate
Hi Irwin! Thanks for this - looks like you've made a good start. So is the idea that foobar playlists keep information about track numbers and other track metadata even if those files are missing? And that we can read that and find the equivalent track in the DB from it? Good call on AcoustID - that's something that wasn't properly available when I started working/thinking on this but should definitely be incorporated. I think I started writing some code to match tracks on MBID but of course that's far too specific. |
Yes, foobar keeps metadata for items in its playlists, even if the items are dead. As far as I know, foo_playlist_revive relies on file size and duration primarily to revive dead items (see https://hydrogenaud.io/index.php/topic,73910.msg651473.html#msg651473). That's why it doesn't work if you converted original files to another format or got them from another source. I believe we can do better than that. Regarding libchromaprint, there are some possible problems with it:
As you see there is a lot of interesting work ahead of us and we have a potential to make a really useful foobar2000 plugin if we implement at least half of the above stated suggestions =) |
|
I started playing with audio fingerprinting to solve a specific problem of mine. I have a lot of music in a specific format, and I want to convert that music to another format. The problem is that I have 300+ playlists that I don't want to recreate manually after the conversion. The existing foo_playlist_revive doesn't work if the tracks are in different formats, and it can operate on single playlist at a time. So I decided to write my own reviving plugin that doesn't need to rely on the tags to do its work. I searched first if there exists already an open source plugin that already does something similar so I could just modify it to do what I need, and I found foo_bestversion. I've noticed that dead item revival is on your planned features list so I thought that my changes could be useful to users of your plugin. If you don't want to include fingerprinting, that is also fine, I will just continue working on it on my own, and you can cherry-pick the changes that you deem useful. It's just I figured that if this functionality is useful to me, it could be also useful to others, and the idea of having different forks of foo_bestversion, one with fingerprinting and one without would be messy and confusing, even if I rename the resulting plugin, it still kind of does the same thing, right? |
Ok, I think we're actually on almost the same page! I'll be happy to incorporate relevant changes you make (I don't have any time to work on this myself but would merge requests and put out new builds). I think you can get what you want (and add useful meaningful functionality for everyone else) with these steps:
The reason I say we're 'almost' on the same page is that I'm afraid I still don't understand why a cached database of fingerprints is needed - it sounds like you're saying you have playlists with files that aren't in foobar's library so need to look up their fingerprints in a cache? Is that right? If that's the case I don't see why you're using a foobar plugin for this task. |
Well, I already started working on the dead item detection across all playlists and so far it looks good. Now, about that database of fingerprints. First of all, even for the music that is in the media library it's generally a good idea to give users the option of not writing the fingerprints into tags. A good example of this is again foo_playcount - there is an option to write (and synchronize) playback statistics with file tags but it is optional. The only potential problem I see now with having the fingerprinting functionality in a separate plugin, is when we want to fingerprint some selected tracks during revival/best version selection process from foo_bestversion. That kind of dll interoperability might get too complex, and to be honest I don't know how to do it. By the way, the current way of title matching for finding the best version has a problem. If the title has a '[' or '(' it just drops what's after. Since there are tracks with (instrumental) or (remix by) or (feat. artist) in title, when looking for the best version it can make a wrong choice. That's why for replacement with library version of the track I made it to match title exactly, and I also think that it should be changed for the best version lookup as well. In future, it would be cool to add an options dialog where you can choose whether to ignore parenthesis in titles, ignore case, accented letters etc. If you've heard about levenshtein distance (fuzzy matching), that also could be added to the options where you can specify how closely titles (and maybe other metadata) should be matched and integrate it into the rating function. Did I clear things up? =) |
Right now it looks for the same artist/album artist, album, track title and track number in the library and replaces selected item(s) with best bitrate. In short, it is the first commit to address #4. I'm planning also to address #8 and convert both picking best version and replacing with library version of the track to using progress bars. Later: