Write cover album art to MP3s, organize files, iTunes import
Write cover album art to MP3s, organize files, iTunes import
Write Album Art is a python script that embeds cover / album art into MP3s downloaded from SABnzbd. Embedding cover art into the ID3 tag is my preferred way of getting cover art to display on all the devices / software that I use to play music (iPod / iPhone, iTunes, XBMC / Plex). The script also helps to organize your music (directory structure and files names) and import your music to iTunes.
For Windows users, choose the EXE file from below. Mac / Linux users running this from the Python source code will need an Amazon AWS Key and also a secondary AWS Secret Key that you can find in your Amazon Web Services Account. You'll need to sign up for Amazon Web Services if you don't already have a login.
Features
* Fetch and store album art into MP3 within SABnzbd
* Add MP3s to iTunes
* Remove extra files (.sfv, .nfo, .m3u)
* Fill in empty ID3 tags from Newzbin title, including empty track numbers
* Nested directory structure - Music/Artist/Album
* Soundtrack support
* Remove comments from ID3 tag
* Update XBMC / Plex library
* Move file to new directory after processing
* Rename files to "01 - title.mp3" or "01 - artist - title.mp3"
Updated to v0.6.5 - 12/20/2011 - currently not working, will update this soon
Updated with Amazon Associate Tag: You can add your own associate tag, but any random string will work. I've added a default random string. (If for some reason Amazon starts requiring a valid Associate Tag you'll need to sign up for that too)
Source (v0.6.0) - requires AMZN AWS Key and also a secondary AWS Secret Key
This works on Snow Leopard, but not tested on Leopard, Lion or on Linux.
http://dl.dropbox.com/u/17457/write_alb ... 6-dist.zip
Win EXE (v0.5)
http://cli.gs/E4Z5mE
Requirements and install details
http://kins.net/wordpress/2008/09/27/sa ... s-to-mp3s/
Updated to v0.4 - 10/31/08
Major changes
* Windows executable now available, Python not required for Windows *NEW*
* Configuration now in ini file: waa_conf.ini - (to support Win32 exe) *NEW*
* Move and rename files feature *NEW*
For Windows users, choose the EXE file from below. Mac / Linux users running this from the Python source code will need an Amazon AWS Key and also a secondary AWS Secret Key that you can find in your Amazon Web Services Account. You'll need to sign up for Amazon Web Services if you don't already have a login.
Features
* Fetch and store album art into MP3 within SABnzbd
* Add MP3s to iTunes
* Remove extra files (.sfv, .nfo, .m3u)
* Fill in empty ID3 tags from Newzbin title, including empty track numbers
* Nested directory structure - Music/Artist/Album
* Soundtrack support
* Remove comments from ID3 tag
* Update XBMC / Plex library
* Move file to new directory after processing
* Rename files to "01 - title.mp3" or "01 - artist - title.mp3"
Updated to v0.6.5 - 12/20/2011 - currently not working, will update this soon
Updated with Amazon Associate Tag: You can add your own associate tag, but any random string will work. I've added a default random string. (If for some reason Amazon starts requiring a valid Associate Tag you'll need to sign up for that too)
Source (v0.6.0) - requires AMZN AWS Key and also a secondary AWS Secret Key
This works on Snow Leopard, but not tested on Leopard, Lion or on Linux.
http://dl.dropbox.com/u/17457/write_alb ... 6-dist.zip
Win EXE (v0.5)
http://cli.gs/E4Z5mE
Requirements and install details
http://kins.net/wordpress/2008/09/27/sa ... s-to-mp3s/
Updated to v0.4 - 10/31/08
Major changes
* Windows executable now available, Python not required for Windows *NEW*
* Configuration now in ini file: waa_conf.ini - (to support Win32 exe) *NEW*
* Move and rename files feature *NEW*
Last edited by zakharm on December 21st, 2011, 12:46 pm, edited 5 times in total.
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
This looks great, thanks for sharing. Gonna test it out now!
Re: Write cover / album art images to MP3s - Win / Mac Python script
Great script !
Working fine on Mac.
Just have to chmod +x your script.
Working fine on Mac.
Just have to chmod +x your script.
Re: Write cover / album art images to MP3s - Win / Mac Python script
Great, thanks!rAf wrote: Great script !
Working fine on Mac.
Just have to chmod +x your script.
I was wondering if the permissions needed to be changed, I'll it add it to the instructions.
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
I havent manage to test this out yet, but does it only do the album art? no artist and title imformation?
Re: Write cover / album art images to MP3s - Win / Mac Python script
Yeah, the script requires that the artist and album are already in the tag. It uses that existing information to find the album art.JayBird wrote: I havent manage to test this out yet, but does it only do the album art? no artist and title imformation?
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
Ah yeah, silly me...how else would it find the cover.
I find a lot of stuff downloaded from usenet doesn't have any ID3 info
I find a lot of stuff downloaded from usenet doesn't have any ID3 info
Re: Write cover / album art images to MP3s - Win / Mac Python script
I could probably look it from the Newzbin title, but there are some exceptions to look out for: VA - Various Artists and maybe OST - Original Soundtrack posts.
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
Yeah, that could be nice!
Is there any possibilty of auto importing downloaded music into the iTunes library?!
Is there any possibilty of auto importing downloaded music into the iTunes library?!
Re: Write cover / album art images to MP3s - Win / Mac Python script
That is a great point. I still don't know why you can't have a "watch" directory in iTunes. I wonder if there is a utility for Mac / PC out there that would do it.JayBird wrote: Is there any possibilty of auto importing downloaded music into the iTunes library?!
As for my script, I can do it if there is a Python library out there or attempt to interface with an existing Apple script.
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
Is it possible to initiate an automator script from SAB?
if so i have seen a few automator scripts that import new files to itunes
e.g. http://www.robertvenema.nl/journal/arch ... -mac-os-x/
if so i have seen a few automator scripts that import new files to itunes
e.g. http://www.robertvenema.nl/journal/arch ... -mac-os-x/
Re: Write cover / album art images to MP3s - Win / Mac Python script
Just after a quick look, there might be a way on the Mac to do it without adding anything to my script.
In Finder you can set "Folder Actions" for a folder. When files are added to the folder it will run an AppleScript that will add the files to your iTunes library.
Folder Actions and iTunes
http://dougscripts.com/itunes/itinfo/folderaction01.php
Also, there is addToLib
http://dougscripts.com/itunes/scripts/s ... p=addtolib
I haven't tried either of these, but they look promising. I don't know if they'll recurse into the folder that SAB will add for your music.
Let me know if you have any luck with these.
In Finder you can set "Folder Actions" for a folder. When files are added to the folder it will run an AppleScript that will add the files to your iTunes library.
Folder Actions and iTunes
http://dougscripts.com/itunes/itinfo/folderaction01.php
Also, there is addToLib
http://dougscripts.com/itunes/scripts/s ... p=addtolib
I haven't tried either of these, but they look promising. I don't know if they'll recurse into the folder that SAB will add for your music.
Let me know if you have any luck with these.
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
I'm getting this:
( was changed by me)
Any idea what's wrong ? Did everything as described and got the Amazon Key...
st
Code: Select all
Traceback (most recent call last):
File "/Applications/SABnzbdPlus/Scripts/write_album_art.py", line 137, in <module>
os.remove(IMAGE)
OSError: [Errno 2] No such file or directory: '/usenet/downloads/Music/<test>/album_cover.jpg'
Any idea what's wrong ? Did everything as described and got the Amazon Key...
st
Re: Write cover / album art images to MP3s - Win / Mac Python script
I don't have a check in there to see if album_cover.jpg actually exists when it tries to remove it. It probably means that it didn't go out to Amazon to fetch your cover. It will say "Fetch art from AMZN" or something when it does go out to Amazon.stanpete wrote: I'm getting this:
( was changed by me)Code: Select all
Traceback (most recent call last): File "/Applications/SABnzbdPlus/Scripts/write_album_art.py", line 137, in <module> os.remove(IMAGE) OSError: [Errno 2] No such file or directory: '/usenet/downloads/Music/<test>/album_cover.jpg'
Any idea what's wrong ? Did everything as described and got the Amazon Key...
st
Did the MP3s have Artist and Album in the tag?
Write album art post processing script
Re: Write cover / album art images to MP3s - Win / Mac Python script
Oh, it said "Fetch art from AMZN" right above my error message. Forgot to include it in my post.
And yes, the files had all the important information.
Don't get it...
st
And yes, the files had all the important information.
Don't get it...
st