Questions tagged [eyed3]

eyeD3 is a Python tool for working with audio files, specifically mp3 files containing ID3 metadata (i.e. song info).

It provides a command-line tool (eyeD3) and a Python library (import eyed3) that can be used to write your own applications or plugins that are callable from the command-line tool.

For example, to set some song information in an mp3 file called song.mp3:

$ eyeD3 -a Nobunny -A "Love Visions" -t "I Am a Girlfriend" -n 4 song.mp3

With this command we’ve set the artist (-a/--artist), album (-A/--album), title (-t/--title), and track number (-n/--track-num) properties in the ID3 tag of the file.
This is the standard interface that eyeD3 has always had in the past, therefore it is also the default plugin when no other is specified.

The results of this command can be seen by running the eyeD3 with no options.

$ eyeD3 song.mp3
song.mp3      [ 3.06 MB ]
-------------------------------------------------------------------------
ID3 v2.4:
title: I Am a Girlfriend
artist: Nobunny
album: Love Visions
track: 4
-------------------------------------------------------------------------

The same can be accomplished using Python.

import eyed3

audiofile = eyed3.load("song.mp3")
audiofile.tag.artist = u"Nobunny"
audiofile.tag.album = u"Love Visions"
audiofile.tag.title = u"I Am a Girlfriend"
audiofile.tag.track_num = 4

audiofile.tag.save()

eyeD3 is written and maintained by Travis Shirk and is licensed under version 2 of the GPL.

Features

  • Python package for writing application and/or plugins.
  • Command-line tool driver script that supports plugins. viewer/editor interface.
  • Easy editing/viewing of audio metadata from the command-line, using the ‘classic’ plugin.
  • Support for ID3 versions 1.x, 2.2 (read-only), 2.3, and 2.4.
  • Support for the MP3 audio format exposing details such as play time, bit rate, sampling frequency, etc.
  • Abstract design allowing future support for different audio formats and metadata containers.
88 questions
0
votes
1 answer

UnicodeEncodeError: 'latin-1' codec can't encode character u'\u2019' in position 4: ordinal not in range(256)

I am using eyeD3 to edit metadata of mp3 files. I am unable to set lyrics tag. def fetch_lyrics(title, artist): URL='http://makeitpersonal.co/lyrics?artist=%s&title=%s' webaddr=(URL %(artist, title)).replace(" ", "%20") print webaddr …
toothie
  • 1,019
  • 4
  • 20
  • 47
0
votes
1 answer

eyed3 file from bytes

Is it possible to modify the tags of a downloaded MP3, without writing it to the disk? I am using def downloadTrack(url) track_data = requests.get(url) audiofile = Mp3AudioInherited(track_data.content) audiofile.initTag() with the…
kf198
  • 35
  • 1
  • 5
0
votes
1 answer

Python eyed3 : How to get lyrics of a song?

Using eyed3, how can i get or set lyrics of a song ? I tried this audiofile.tag.lyrics.get() But the method is asking for a parameter, and i have no idea what it should be. The documentation at this link is unclear (i guess its not complete…
Rupam
  • 1,502
  • 13
  • 23
0
votes
1 answer

Processing chinese character using eyed3 in python

I am using eyed3 to add lyrics, and I had this code for it #-*-coding:utf-8-*- import eyed3 mp3 = eyed3.load( r'F:\Music\=NEUTRAL=\桜華結界-Perfect Cherry Blossom-\04 - 早乙女の遊戯そして流儀(原曲:東方紅魔郷…
tonyrft
  • 1
  • 1
0
votes
1 answer

eyeD3 -- recursive Tag removal

I want to recursively remove all ID3v1/ID3v2-tags of my mp3-files with eyeD3. Can't get it work. The slim doc doesn't say much about the PATH-variable and its usage. usage: eyeD3 [-h] [--version] [--exclude PATTERN] [--plugins]…
user3300331
0
votes
0 answers

Python for loop bug

I have a list full of filepaths to mp3 files. print ("/home/jds/Music/Other Songs/Supernatural.mp3" in mp3_files) #prints True for f in mp3_files: if '/home/jds/Music/Other Songs/Supernatural.mp3' == f : print "Gotcha" mp3 =…
Davlog
  • 2,162
  • 8
  • 36
  • 60
0
votes
1 answer

Python eyed3 check for embedded image

I need a script to check a whole directory for mp3 files without an embedded image. This function should return such a list. def checkAlbumCover( file_list ): ret = list() #list with mp3 files without album cover for f in file_list: …
Davlog
  • 2,162
  • 8
  • 36
  • 60
0
votes
2 answers

Bash: How to use a variable as an argument with multiple sets of quotes

I have a folder full of mp3s and I want to strip out all id3 usertext frames (except replaygain) - this code I wrote will do it, but it will loop through each file, for each found tag, to remove it. This results in the script cycling over each mp3…
EightBall
  • 87
  • 1
  • 2
  • 7
0
votes
1 answer

python mutagen eyed3 write id3v1 tag

I am using mutagen to manipulate my mp3's but I am finding it hard to write id3v1 tags using this, looks like the popular eyed3 package also doesnt not give any examples on how to do this. Can anyone who has worked on mutagen and eyed3 give me…
Prem Minister
  • 407
  • 2
  • 10
  • 20
0
votes
1 answer

load remote url with eyed3

I have been working with eyed3 for a while now and I have been using it to extract the genre of the mp3 files this way import eyed3 audiofile = eyed3.load(path) print audiofile.tag.genre.name Now I have a URL like this, www.example.com/abc.mp3.…
Anurag Ramdasan
  • 4,189
  • 4
  • 31
  • 53
-1
votes
1 answer

How can I compare the cover art of 2 MP3 file using python: eyed3?

I am writing my own sync file for MP3 between my computer and MP3 player. I can catch new file, change in the name, artist, etc... but find if I have updated the cover is harder.
Benji_90210
  • 25
  • 1
  • 7
-2
votes
1 answer

How to get an audio file's artist and set album artist equal to artist in idv2.4 tagwith eyed3

I have a large collection of audio files and for each audio file, I would like to get the value of "artist" and set "album artist" with the value I get from "artist".
jlanssie
  • 97
  • 10
-2
votes
1 answer

ImportError (libmagic) when using eyed3 module

Am a newbie to Python and is trying to use eyed3 module. Here is my code. import eyed3 def GetAlbumName(filename): tag = eyed3.tag() I am running into exception Exception has occurred: ImportError failed to find libmagic As explained in the…
Anu Viswan
  • 17,797
  • 2
  • 22
  • 51
1 2 3 4 5
6