getmusicbee.com

MusicBee & Add-Ons => Customizations => Plugins => Topic started by: Steven on July 15, 2012, 09:27:50 PM

Title: Last.fm Playlist Generator
Post by: Steven on July 15, 2012, 09:27:50 PM
This plugin enables various types of playlists to be created based on information from last.fm - some of the functions are based on data from your last.fm account, and need to have logged in to last.fm at least once with MusicBee but you dont need to be logged in at the time of using this functionality. You do not need a last.fm account to use the "Artist" and the "Similar Artist" functions.
- Library Top Tracks
    - the most played tracks (according to your last.fm library) over a period of time that are in your library:
      Overall, Last year, Last 6 months, Last 3 months, Last week
- Loved tracks
- Last.fm playlist (ie. a playlist that has been saved on last.fm)
- Genre 'xxx' Top Tracks - the most played tracks (all users of last.fm) for a genre - the available tags are the top 20 genre tags from your library, plus 5 custom ones you can enter yourself
- Artist 'xxxx' Top Tracks
    - for the selected artist, the most played tracks (all users of last.fm) that are in your library
- Similar Artist 'xxxx' Top Tracks
    - for the selected artist, the most played tracks (all users of last.fm) for that artist or any similar artists

Usage
right click in the main panel/ Last.fm Playlist/ ...
  - Save Tracks To -> you can save to a New Playlist (default)/ Now Playing List/ or choose an existing playlist
  - select one of the above commands

if you dont see "Last.fm Playlist" at the bottom of the context menu, it means the plugin is not enabled in Preferences/ Plugins

Installation
- unzip the plugin: https://getmusicbee.com/download/plugins/mb_LastFmPlaylistPlugin.zip (https://getmusicbee.com/download/plugins/mb_LastFmPlaylistPlugin.zip)
- copy the files to the Plugins sub-folder of MusicBee
Title: Re: Last.fm Playlist Generator
Post by: Thorbjorn on July 15, 2012, 10:04:14 PM
Ok, this is amazing Steven! Great work.
It doesn't update itself right? I have to make a new playlist to e.g. get the last weeks top played songs
Title: Re: Last.fm Playlist Generator
Post by: beeing good on July 15, 2012, 10:23:53 PM
This is very cool Steven, thanks for this!
Title: Re: Last.fm Playlist Generator
Post by: SimonBRT on July 16, 2012, 05:30:10 AM
Fantastic!
Title: Re: Last.fm Playlist Generator
Post by: Alexis on July 16, 2012, 05:31:00 AM
This is really pretty cool work, even as far as I have gotten, but may i ask for some clarification...  

Is this confined to the songs in my library (I think you have indicated such, but seeking confirmation)?  
Eg, if i have two KT Tunstall songs in my library and I  select top tracks by KT Tunstall... It populates the playlist with songs from  my library, so the most  the result could be is said two tracks?

The fact that you said that one does not always need to be logged into Last.fm after the initial login, further indicates that this is the case.  Correct?

Title: Re: Last.fm Playlist Generator
Post by: Steven on July 16, 2012, 06:22:44 AM
yes only local files - you cant choose specific tracks and stream them from last.fm
also its only when a match can be made - sometimes last.fm stores a different variation to the tags you use and so MB can't make a match
Title: Re: Last.fm Playlist Generator
Post by: dual-o on July 16, 2012, 07:16:01 AM
Thanks for this great Plugin! Its the only feature I miss since change from mediamonkey. I'll test it this afternoon.

big THX
by a big fan from germany!
Title: Re: Last.fm Playlist Generator
Post by: Alexis on July 16, 2012, 01:08:53 PM
Thank you for the confirmation/clarification Steven... Very thankful.
Title: Re: Last.fm Playlist Generator
Post by: Greb on July 16, 2012, 06:35:04 PM
Amazing plugin!  :)
Title: Re: Last.fm Playlist Generator
Post by: richardap1 on July 16, 2012, 08:10:30 PM
Awesome, as always. But would it be possible to enable it for artwork view too?
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 16, 2012, 09:25:47 PM
Awesome, as always. But would it be possible to enable it for artwork view too?
yes thats been included for the next update
Title: Re: Last.fm Playlist Generator
Post by: beeing good on July 16, 2012, 10:05:27 PM
When we send these lists to a playlist what order is it being shown in? The songs don't seem to be shown by playcount order for the most played tracks (according to my last.fm library).
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 16, 2012, 10:07:48 PM
the artist ones are sorted on playcounts of all last.fm users
the Top Library Tracks ones are sorted on playcount in your last.fm library

Awesome, as always. But would it be possible to enable it for artwork view too?
http://musicbee.niblseed.com/V2/MusicBee_Exe_Patched.zip
Title: Re: Last.fm Playlist Generator
Post by: beeing good on July 16, 2012, 10:24:37 PM

the Top Library Tracks ones are sorted on playcount in your last.fm library

I have my playcount synced to my lastfm playcount but it isn't sorted by playcount:

http://i.imgur.com/zxu9D.jpg
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 16, 2012, 10:33:38 PM
maybe display in track details view and make sure the playlist is displayed unsorted (Sort By/ Playlist order)
checking the code and its definitely generating the playlist with tracks in the order that last.fm is ranking them - if you are still convinced its wrong then PM me your last.fm user id so i can check the query results myself
Title: Re: Last.fm Playlist Generator
Post by: beeing good on July 16, 2012, 11:07:20 PM
I suspect the plugin is not doing anything wrong, I've just looked in Lastfm and the few that I checked seem to make sense according to the playlist created but I noticed that the playcount in Musicbee isn't matching the lastfm ones, even though I sync it. The tags appear to be the same.
Title: Re: Last.fm Playlist Generator
Post by: lnminente on July 16, 2012, 11:24:57 PM
Hi, Steven i have configured MB to connect using a proxy in Preferences\Internet\Proxy settings\Server, but i see this plugin is not using it. Actually is not a problem for my case, but it could not work well for other people.

The plugin is very useful! I will relisten some songs i rated poorly in comparison with the top artist tracks :)
Title: Re: Last.fm Playlist Generator
Post by: Guegs on July 17, 2012, 01:28:18 AM
Thanks for the plugin Steven, but is there a way to get more than 10 tracks for the artists top tracks?
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 17, 2012, 06:24:52 AM
Hi, Steven i have configured MB to connect using a proxy in Preferences\Internet\Proxy settings\Server, but i see this plugin is not using it. Actually is not a problem for my case, but it could not work well for other people.
yes you are right and i would need to add in support for that

I suspect the plugin is not doing anything wrong, I've just looked in Lastfm and the few that I checked seem to make sense according to the playlist created but I noticed that the playcount in Musicbee isn't matching the lastfm ones, even though I sync it. The tags appear to be the same.
the plugin (or more specifically the available last.fm query) is based on the artist and title total playcount.
The playcount sync is based on album, artist and title, so you would need sum all the album variations and compare the ranking of that number.
However i now realise the created playlist will take on the current default sort order for playlists, so i will change it to be forced to display and Track Detail view and unsorted.

Thanks for the plugin Steven, but is there a way to get more than 10 tracks for the artists top tracks?
it is matching 30 tracks per artist from the top 100 tracks for the artist according to last.fm. If you see less then it is not able to match to your library or your library tracks are not in the top 100 for the artist
Title: Re: Last.fm Playlist Generator
Post by: Greb on July 17, 2012, 07:52:34 AM
It could be interesting to match not only specific artist top tracks, but specific last.fm genre top tracks.

For example: I have every celtic song in my library under the tag 'Celtic'. But artists in last.fm have more specific and detailed tracks. Let's say that 'Silly Wizard' is a very traditional group in Scottish Celtic music. Now I can make a playlist with 'Top track similar to Silly Wizard'. Why not to make a playlist with 'Top tracks in songs tagged as 'Scottish folk' in last.fm'?
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 17, 2012, 10:26:11 PM
http://www.mediafire.com/?bxryf59d91bvqxz
and
http://musicbee.niblseed.com/V2/MusicBee_Exe_Patched.zip

It could be interesting to match not only specific artist top tracks, but specific last.fm genre top tracks.

For example: I have every celtic song in my library under the tag 'Celtic'. But artists in last.fm have more specific and detailed tracks. Let's say that 'Silly Wizard' is a very traditional group in Scottish Celtic music. Now I can make a playlist with 'Top track similar to Silly Wizard'. Why not to make a playlist with 'Top tracks in songs tagged as 'Scottish folk' in last.fm'?
thats already supported but i have moved it to the top level of the last.fm context menu so its more obvious. Additionally i have allowed entry of 5 custom genres (the others are the most used ones in your library)

Thanks for the plugin Steven, but is there a way to get more than 10 tracks for the artists top tracks?
it is matching 30 tracks per artist from the top 100 tracks for the artist according to last.fm. If you see less then it is not able to match to your library or your library tracks are not in the top 100 for the artist
i was wrong about that and infact was limiting it to 10 - its now 30 and matches from the top 250 artist tracks
Title: Re: Last.fm Playlist Generator
Post by: Greb on July 18, 2012, 06:30:39 AM
Nice! (though it crashed MB a couple of times until I could make it work)

One issue... it's very easy to have like a lot of 'Top track...' playlists in the left bar quite quickly. Would be interesting to be able to configurate the plugin so it sends every new playlist, for example, to a 'LastFM' folder. That way the left bar would be more organized.
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 18, 2012, 06:59:10 AM
you probably need the latest for the crashing
http://musicbee.niblseed.com/V2/MusicBee_Exe_Patched.zip
Title: Re: Last.fm Playlist Generator
Post by: gladtobeblazed on July 18, 2012, 10:00:17 AM
This is a really cool plugin, but I noticed that it's putting alternative or live tracks, with few playcounts, ahead of the studio album tracks.

For example, my overall most played song is "Boyfriend", off the album "Crazy For You", but the playlist gives me "Boyfriend" from the "iTunes Session" album instead. The artist and track name are correct, just not the album.
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 18, 2012, 06:11:46 PM
only the "Library Top Tracks" query in last.fm returns album information. Other queries such as artist specific ones are based on overall last.fm counts for the artist and track only. What MB does is choose the highest quality file if that artist and track are on multiple albums. Highest quality being a lossless format, then m4a, then lossy such as mp3 at the bottom. I guess one change that could be made is if multiple albums match and they are all lossy formats then choose the album with the highest playcount according to MusicBee but then that would be confusing because it wouldnt be consistent if you were expecting it to choose the highest album playcount
Title: Re: Last.fm Playlist Generator
Post by: lnminente on July 18, 2012, 07:43:07 PM
BUG: Latest version can't connect to internet, it says "Error - The proxy name could not be resolved: 'h'"
I use localhost, have tried 127.0.0.1 but neither works. TIA
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 18, 2012, 09:05:00 PM
http://www.mediafire.com/?ij7qsv1c5ko9rur
http://musicbee.niblseed.com/V2/MusicBee_Exe_Patched.zip

You can now specify a folder to save the generated playlists
it should also fix the web proxy bug
Title: Re: Last.fm Playlist Generator
Post by: Greb on July 18, 2012, 09:16:14 PM
you probably need the latest for the crashing
http://musicbee.niblseed.com/V2/MusicBee_Exe_Patched.zip


Thanks, it worked perfect (though I just saw there's already a new one with the folders!  ;D)
Title: Re: Last.fm Playlist Generator
Post by: lnminente on July 18, 2012, 11:31:08 PM
SOLVED: The plugin is sucesfully connecting to internet across my local proxy. Thanks :)
Title: Re: Last.fm Playlist Generator
Post by: intripletime on July 22, 2012, 04:35:20 AM
Interesting, Musicbee crashes after I have copied this plugin to the 'Plugins' folder. I'm running Windows 7 64 bit and the latest beta version of Musicbee.
Title: Re: Last.fm Playlist Generator
Post by: Alexis on July 22, 2012, 04:50:16 AM
the latest Beta version of MusicBee is something like this  2.0.4583... at least that is what I am using.  What is your version number?

Make sure if you are using this plugin that you also installed the version of musicbee that Steven has in the post.
Title: Re: Last.fm Playlist Generator
Post by: intripletime on July 22, 2012, 05:02:30 AM
Thankyou. I had the latest from the "Latest Beta" forum (2.0.4573), but it seems that wasn't the latest!
Title: Re: Last.fm Playlist Generator
Post by: Alexis on July 22, 2012, 05:03:15 AM
No problem... Did that resolve your issue?
Title: Re: Last.fm Playlist Generator
Post by: intripletime on July 22, 2012, 07:11:26 AM
It did indeed! Enjoying the playlist generator now.
Title: Re: Last.fm Playlist Generator
Post by: Alexis on July 22, 2012, 07:13:33 AM
Awesome.  Good luck.
Title: Re: Last.fm Playlist Generator
Post by: Steven on July 22, 2012, 08:31:21 PM
the artist and track title matching has been tweaked to allow some fuzziness in the comparison (this should help for when last.fm normalises the artist and track title to be different to what you have tagged locally)

see the first post for updated links - you need both the updated plugin and latest version 2 beta of musicbee
Title: Re: Last.fm Playlist Generator
Post by: timelezz on October 02, 2012, 05:03:13 PM
I retrieve a timeout error when querying for 'top track playlist'
A weekly playlist works good though.
Title: Re: Last.fm Playlist Generator
Post by: Carbon6 on October 02, 2012, 08:40:21 PM
Holy crap, I just stumbled across this..I've been missing out for so long, Frankly, this is fantastic, Good job Steven!
Title: Re: Last.fm Playlist Generator
Post by: Carbon6 on October 03, 2012, 05:46:00 PM
Although, I get operation timed out about 80% of the time.
Would it be possible to have some kind of auto-retry option?
Title: Re: Last.fm Playlist Generator
Post by: Steven on October 03, 2012, 07:11:57 PM
i've noticed last.fm queries taking a lot longer to run lately as well.
I have doubled the timeout period on the plugin web requests:
http://www.mediafire.com/?jxvjs0s48jaapo4
Title: Re: Last.fm Playlist Generator
Post by: Saragis on November 22, 2012, 12:26:08 AM
Any chance for auto-updating lists for this in the future?
Title: Re: Last.fm Playlist Generator
Post by: dual-o on April 26, 2013, 08:04:50 AM
Hi,

it's the most important plugin for me. Will there be an update in future?
I think the song selection can be better.

thanks for the great work!

dual-o
Title: Re: Last.fm Playlist Generator
Post by: boroda on June 26, 2013, 07:53:17 AM
Here is plugin's wiki page (http://musicbee.wikia.com/wiki/Last.fm_Plugins). Please update it if plugin is updated.
Title: Re: Last.fm Playlist Generator
Post by: BlackFervor on December 05, 2015, 04:57:50 AM
Hello my dear friends.
I absolutely love this plugin and still continue to use it after almost a year.
The main function I use is the import of the Loved Tracks, so I noticed my problem there first, but it's also present with the other features.
Whenever I try to create a new playlist via the plugin, the maximum of tracks in that playlist will be at 490 for some reason. Of course I tried loving a few more songs on Last.fm, but it still just imports the last 490 I favourited.
I hope someone here knows how to fix this, or if it even is fixable.
Thanks in advance C:
Title: Re: Last.fm Playlist Generator
Post by: Steven on January 24, 2016, 09:07:38 AM
the plugin has been updated to support retrieving more than 500 loved tracks
Title: Re: Last.fm Playlist Generator
Post by: BlackFervor on January 25, 2016, 12:41:21 PM
the plugin has been updated to support retrieving more than 500 loved tracks
Thank you!
Title: Re: Last.fm Playlist Generator
Post by: jaume on February 02, 2016, 07:06:45 PM
Many thanks, Steven :)
Title: Re: Last.fm Playlist Generator
Post by: Lemodile on April 08, 2016, 08:52:55 PM
Hello!

Not sure if this plugin is still updated or not. Anyway, it seems to be what I've been looking for. I'd like to make a playlist with my loved tracks from Last.fm in it. However, I have 0 experience with getting plugins on MusicBee and the instructions here unfortunately aren't getting me anywhere...

I have the plugin downloaded, in the proper folder and it's listed as enabled under my preferences. But that's as far as I have managed to get with it. The instructions say to right click somewhere but no matter where I click, I get no entry anywhere that even remotely hints at being this plugin.

Any help would be hugely appreciated: How do I set up a playlist that has my Last.fm loved songs in it using this plugin?

Thanks
Title: Re: Last.fm Playlist Generator
Post by: lamensterms on July 20, 2017, 04:08:56 AM
Great plug-in, thanks a lot for this.

To create a last.fm playlist, right-click in the song list or library panel.  Last.fm playlist menu should be at bottom of context menu.
Title: Re: Last.fm Playlist Generator
Post by: memoria on May 01, 2019, 02:06:55 AM
I love this plugin but is there anyway we can increase the maximum output from 30 tracks to unlimited? I have a few artists with 100s of tracks and I'd like to see if any of the songs I've overlooked are unusually popular. Amazing work!
Title: Re: Last.fm Playlist Generator
Post by: Z Tetriminos on March 05, 2020, 12:25:55 AM
I'd love to see an option where you could actually select how many tracks you want in your playlist.
Sometimes I want to make a playlist with just my 30-75 most played tracks in the last 3 months, but it makes a playlist with all the 500 tracks I listened to in the selected time span... Might as well shuffle my entire library  ;D

I'm sorry if that option already exists and I just couldn't find it...
Title: Re: Last.fm Playlist Generator
Post by: SonicRings on May 23, 2021, 09:25:14 AM
I absolutely love this plugin! I can't believe I haven't found it until now. This pleases me so much.

Just one request: is it at all possible to give us more granular control over the timeframes? For example, I'd like to make a playlist of my most listened to songs from the past 2 weeks, or 1 month. Currently, the only choices we're given are 1 week/3 months/6 months/year/overall.

I'd love to see an option where you could actually select how many tracks you want in your playlist.
Sometimes I want to make a playlist with just my 30-75 most played tracks in the last 3 months, but it makes a playlist with all the 500 tracks I listened to in the selected time span... Might as well shuffle my entire library  ;D

I'm sorry if that option already exists and I just couldn't find it...

Can't you just remove the tracks yourself?
Title: Re: Last.fm Playlist Generator
Post by: SonicRings on May 25, 2021, 03:53:38 AM
I've been listening to the playlist this plugin has generated based on my top tracks [3 months]. An issue I'm noticing is that the playlists that are created include the wrong song when there are multiple tracks in my library with the same title. It doesn't seem to take the album tag into account, nor the year. It looks like it's strictly looking at titles and taking the first match.

For example, there's a track by the artist "insaneintherainmusic" with the following tags:

Title: Sunyshore City
Album: Year 3 Collection
Year: 2016

Title: Sunyshore City (From "Pokemon Diamond / Pearl / Platinum")
Album: Sunyshore City (From "Pokemon Diamond / Pearl / Platinum")
Year: 2020

Title: Sunyshore City
Album: Sinnohvation
Year: 2020

The last two tracks here are identical. They're the same track. One's a single, the other's in an album. My "most listened to" track in this case is the third one. However, the first one from 4 years prior has the same title, so that's the one that incorrectly got added to the playlist instead of the third one.

Now if the plugin checked for album tag, the third one would have been correctly added.

This has happened about a dozen times so far. Some cases it's just a single whose album version was used in its stead (and vice versa), both of which being identical songs so it's fine. Other cases it's an album version vs. a dj-mix version. And there are cases like I just described where the old version is used when the new one should be used.

If this plugin can consider more than just the title tag, I believe these issues would be resolved.
Title: Re: Last.fm Playlist Generator
Post by: so_la_la on February 01, 2022, 03:45:11 PM
it is matching 30 tracks per artist from the top 100 tracks for the artist according to last.fm. If you see less then it is not able to match to your library or your library tracks are not in the top 100 for the artist
Hello and thanks for this plugin.
Could it be that the plugin only includes each title once?
Like most users (I guess) I have a lot of songs in various formats and from various albums (Greatest Hits, Live etc.)
It seems that the plugin does not include these?
Sometimes the plugin returned flacs only, sometimes it seems to have selected the version at random?
Thanks!
Title: Re: Last.fm Playlist Generator
Post by: so_la_la on February 01, 2022, 05:58:56 PM
only the "Library Top Tracks" query in last.fm returns album information. Other queries such as artist specific ones are based on overall last.fm counts for the artist and track only. What MB does is choose the highest quality file if that artist and track are on multiple albums. Highest quality being a lossless format, then m4a, then lossy such as mp3 at the bottom. I guess one change that could be made is if multiple albums match and they are all lossy formats then choose the album with the highest playcount according to MusicBee but then that would be confusing because it wouldnt be consistent if you were expecting it to choose the highest album playcount
Ok I have found this so obviously this is not supported.
I have one more question though:
How far back in time will the plugin compute an artist's top tracks?
I have tried the plugin on my Pretenders (https://en.wikipedia.org/wiki/The_Pretenders) files and the top ranked track I get is "Spiritual High". I do not get any number returned for "Brass in Pocket", "Don't Get Me Wrong" or "Kid". Obviously the artist's most popular tracks in general did not get ranked.