Win Beets+SABnzbd: Automate your music tagging - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33) +--- Forum: Supplementary Tools for Kodi (https://forum.kodi.tv/forumdisplay.php?fid=116) +--- Thread: Win Beets+SABnzbd: Automate your music tagging (/showthread.php?tid=189897) |
Beets+SABnzbd: Automate your music tagging - helta - 2014-03-22 This guide is for people who want to automate their music tagging from MusicBrainz after downloading from SABnzbd. Let me begin by saying that if you do not use MusicBrainz data in your tags, then stop reading. I always hated having to open supplimentary tools like Picard to tag my recently acquired music. There is something clunky about downloading with SAB, then opening another program, properly tagging, embedding art etc, then finally moving it into your library. Why can't this be scripted..... ohh wait, it can! I came across an amazing CLI tool called Beets!. This program is amazingly powerful and down right effective. I won't get into how to install, because the authors of Beets have already made a Getting Started Guide. Beets does all sorts of amazing things, but for this guide we will focus on just a couple of things when it comes to integration with SABnzbd and some of my preferred Beets settings. Heres what will happen if you follow this guide: An album gets downloaded with SABnzbd. SABnzbd will call on Beets. Beets will match the album via MusicBrainz and update tags/download cover art/embed cover art and finally move it into your final library folder. If it can't find a suitable match, it will exit gracefully and do nothing. My Beets Settings: So I will assume you have at least created the beets config.yaml in the appropriate directory, you did follow the Getting Started Guide right? RIGHT? Open up the config.yaml with a decent text editor and paste the following below your "library:" line. Code: import: So what exactly does that config do, lets break it down: Code: import: Code: plugins: fetchart embedart Code: id3v23: yes Quote:By default, beets writes MP3 tags using the ID3v2.4 standard, the latest version of ID3. Enable this option to instead use the older ID3v2.3 standard, which is preferred by certain older software such as Windows Media Player. Code: match: This is where things get interesting.... Quote:The threshold is a distance value between 0.0 and 1.0, so you can think of it as the opposite of a similarity value. For example, if you want to automatically accept any matches above 90% similarity, use: In my config, I'm using a threshold of 80%, you can obviously change this to a higher rating if you want to make sure your matches are more stringent. Quote:ignored: missing_tracks unmatched_tracks So suppose you download an album, it is missing track 16 of an album it has matched on MusicBrainz, It will not do any more processing at that point and intentionally leave the album untouched. Likewise, if it has extra songs that don't match any known release it will not NOT attempt to tag those albums either. Code: paths: The paths function will sort your physical files after they have been matched. Feel free to change this if your final folder paths do not match my final layout. SABnzbd Configuration: Create a .bat or .cmd file and place it in your SABnzbd "Post Processing Scripts Folder", I named mine beets.bat and my script folder is using Sickbeards "autoProcessTV" folder. Paste the following into the .bat. Code: @echo off In your SABnzbd config page, click the Catagories link. Make sure your music catagory/catagories now use your new beets.bat as its post processing script. Also, it might be worth mentioning to create a temporary music directory (not your final library path) where SAB downloads the music to. In my example, it moves the file to E:\Music (this is not my final library directory). You can do this so that if beets can not find a match it will leave it in that temporary directory so that you can manually tag it, or even better, add the album to MusicBrainz yourself so it can be tagged correctly for others! So after downloading an album with SAB, it will then call on beets as its post processing script and you should end up with something similar to the following: Clicking on the View Script Log from SAB, you can see that beets tagged and changed the following tags and also added MusicBrainz MBID data etc. Code: E:\Music\Jeff_Beck-Best_of_Beck-CD-FLAC-1995 (14 items) If beets does not find a suitable match, beets will exit gracefully and the SAB script log will say "Skipping" and leave the album untouched and not moved. That should be it, everything should now work as advertised. Remember, if beets doesn't process the album, its either because the album doesn't exist on MusicBrainz or it did not find a close enough match. RE: Beets+SABnzbd: Automate your music tagging - helta - 2014-04-03 Updated with some pictures. RE: Beets+SABnzbd: Automate your music tagging - feerlessleadr - 2014-04-03 Very cool, I'll give this a shot tonight. RE: Beets+SABnzbd: Automate your music tagging - MadClicker - 2014-04-03 Looks like a stray colon in your config file. RE: Beets+SABnzbd: Automate your music tagging - helta - 2014-04-03 Quote:Looks like a stray colon in your config file. Good catch MadClicker, fixed. RE: Beets+SABnzbd: Automate your music tagging - paco - 2014-05-10 Thanks for this guide but I wanted to share something that stumped me for a few hours. In order to use the fetchart plugin you need to run the following command: pip install requests By default this is not mentioned in the Getting Started Guide. Only when you click on the fetchart plugin do you find this command. RE: Beets+SABnzbd: Automate your music tagging - Dr. Grinch - 2014-06-12 Addendum to this topic (which was GREAT btw, and has been a huge help!) To get this working properly with SabNZBD you need to go to Config->Switches->Naming and turn ON "Replace Spaces in Folder Names" Otherwise you'll get an error in executing the script that it can't find the folder as soon as it hits the space in the name. RE: Beets+SABnzbd: Automate your music tagging - helta - 2014-06-13 Good catch Dr. Grinch. I had actually set that option a long time ago even before I used Beets. Just a heads up for Windows beets users, the next update 1.3.7 will fix a nasty bug that deals with "special characters" in the filenames. It was extrememly annoying if it has happened to you. RE: Beets+SABnzbd: Automate your music tagging - bry - 2015-10-14 @helta - how is this working out for you? still in use? RE: Beets+SABnzbd: Automate your music tagging - theman480 - 2016-05-16 (2014-06-13, 21:46)helta Wrote: Good catch Dr. Grinch. I had actually set that option a long time ago even before I used Beets. Hello Helta , i know this a old post but can you help me? I am using ubuntu , so i need a sh script, to import on sabnzbd, can you help me make one? Thank you in advice. |