Getting Last.FM Played #'s?

Post a reply

Visual Confirmation

To prevent automated access and spam, you are required to confirm that you are human. Please place a check mark next to all images of monkeys or apes. If you cannot see any images, please contact the Board Administrator.

Smilies
:D :) :( :o :-? 8) :lol: :x :P :oops: :cry: :evil: :roll: :wink:
BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON
Topic review
   

Expand view Topic review: Getting Last.FM Played #'s?

Chance to Look for Album Interpret?

Post by Cadfael » Thu Nov 01, 2012 10:08 am

Salve!

First: sorry for my bad english ;-)

Is there any Chance, to look for the Album Artist in the Database of Mediamonkey?

Thanx for Help,
Andy

Re: Getting Last.FM Played #'s?

Post by sevenalive » Sat Aug 18, 2012 9:19 pm

Any chance for the same thing but for Zune counts on zune.net?

Maybe an option: Zune counts + Local Counts.

Re: Getting Last.FM Played #'s?

Post by Redeye51 » Fri Apr 20, 2012 10:52 am

It's fixed! It's loading my counts as I type this message.

Thanks for you hard work on this.

Re: Getting Last.FM Played #'s?

Post by Psyker7 » Fri Apr 20, 2012 1:38 am

Typo on my part, updated.

Re: Getting Last.FM Played #'s?

Post by Redeye51 » Thu Apr 19, 2012 5:37 pm

I'm getting the following errors during install of you plugin.

Error 1:
Image

Error 2:
Image

Are there prerequisites?

Code: Select all
Dim oShell : Set oShell = CreateObject( "WScript.Shell" )
Dim ScriptFileSaveLocation : ScriptFileSaveLocation = SDB.ScriptsPath&"LastFmImport\"

If Not fso.folderexists(ScriptFileSaveLocation) Then <-- Fails Here
   fso.CreateFolder(ScriptFileSaveLocation)
End If


My System: Windows 7 64bit
MediaMonkey: 4.0.3.1476

Thanks

Re: Getting Last.FM Played #'s?

Post by Psyker7 » Wed Feb 18, 2009 12:40 am

Well here is a vbscript implimentation of a last.fm sync of playcounts.

It will find total playcounts of every track in your last.fm history, check if it is higher than the value in the database (for all tracks of that title/artist - even if multiples) and updates it if so.

My first real scripting attempt for MM, thanks to:
Teknojnky - author of last.fmnode - for code for various functions, hacked a LOT.
Trixmoto - for mmip packaging of normal scripts, had me stumped for a while there :D


Forum thread:
http://www.mediamonkey.com/forum/viewtopic.php?f=2&t=37341

Re: Getting Last.FM Played #'s?

Post by m0nkiii » Tue Feb 17, 2009 3:36 pm

Funkafonik wrote:About the Last.FM playcount feed , I've noticed the feeds don't match perfectly with our Libraries. I've imported Last.FM playcounts to iTunes and WMP with their respective softwares and the numbers weren't all perfect. Would there be any way to parse our own Libraries and get the playcounts from there? Especially now that their auto-correction merges duplicate/misspelled songs and artists, but only in our Libraries.


I've done a script that parses this site: http://www.last.fm/user/USERNAME/tracks
Puts all tracks in a database and makes some stats. Using this data to import to MM should work.
It takes a while to parse though.

http://www.lastfm.shikaka.net/

Re: Getting Last.FM Played #'s?

Post by Funkafonik » Tue Feb 17, 2009 3:21 pm

About the Last.FM playcount feed , I've noticed the feeds don't match perfectly with our Libraries. I've imported Last.FM playcounts to iTunes and WMP with their respective softwares and the numbers weren't all perfect. Would there be any way to parse our own Libraries and get the playcounts from there? Especially now that their auto-correction merges duplicate/misspelled songs and artists, but only in our Libraries.

Re: Getting Last.FM Played #'s?

Post by trixmoto » Tue Feb 17, 2009 7:28 am

When I'm making calls to Last.Fm I always use "Microsoft.XMLDOM" not "MSXML2.DOMDocument.3.0". I've not played with 2.0 calls yet so maybe this won't help you but it's worth a go.

Re: Getting Last.FM Played #'s?

Post by Psyker7 » Mon Feb 16, 2009 11:48 pm

I'm currently in the process of hacking together some pieces to get this working as a single vbscript.

Problem I'm coming up against at the moment is when accessing last.fm's 2.0 xml feeds.

The error I get is "System does not support the specified encoding"
Not quite sure how to get around this - if I save the xml page locally, it works fine.

Code snippet:
Code: Select all
   
         xmlURL = "http://ws.audioscrobbler.com/2.0/?method=user.getWeeklyChartList&user=" & fixurl(user) & "&api_key=daadfc9c6e9b2c549527ccef4af19adb"
      

   Set xmlDoc = CreateObject("MSXML2.DOMDocument.3.0")

   xmlDoc.async = False
   xmlDoc.Load (xmlURL) ' <<<<---- load last.fm xml occurs here

   If (xmlDoc.parseError.errorCode <> 0) Then
      Dim myErr
      Set myErr = xmlDoc.parseError
      MsgBox("You have error " & myErr.reason)
   Else
      'Do more stuff here
   End If

The error is triggered, when I don't understand why.

Example xml page:
http://ws.audioscrobbler.com/2.0/?metho ... ef4af19adb
which appears fine to me :|

Any hints appreciated!

edit: thought i'd add - using the 2.0 api as apparently the 1.0 api no longer lists playcounts O,o

edit #2: found some info here: http://support.microsoft.com/kb/304625 but not quite sure how to implement this - bit beyond my knowledge of msxml

edit #3: (going overboard on edits... meh) - What is strange is the 1.0 API does work to parse the XML at least, it just doesn't have the data I need - eg: http://ws.audioscrobbler.com/1.0/user/p ... kchart.xml

Re: Getting Last.FM Played #'s?

Post by m0nkiii » Tue Feb 10, 2009 11:32 am

Teknojnky wrote:So then, what are you using now?


Spotify! or Last.fm :)

Re: Getting Last.FM Played #'s?

Post by Teknojnky » Tue Feb 10, 2009 11:25 am

So then, what are you using now?

Re: Getting Last.FM Played #'s?

Post by m0nkiii » Tue Feb 10, 2009 11:13 am

Funkafonik wrote:*bump* Any new development on this? it's been a while and lots happened at Last.FM in the meantime with the new Library and auto-corretion going on. I see there's even a Last.FM node available, any ways to now import playcounts to MM?


Sorry to say that I don't use MM anymore. So there has not been any development. (I got a notification in my mail)
edit: oh, I realized now that this wasn't about my script :P

On the other hand I've started an other project :)
I like stats so I've done a stats-site for Last.FM users. I read in ALL tracks and presents some stats.
The data in my database could be used to import it to MM, but like I said I don't use it anymore. If someone does a script that could import to MM I can help with the tracks.
http://lastfm.shikaka.net/

Re: Getting Last.FM Played #'s?

Post by Funkafonik » Tue Feb 10, 2009 8:29 am

*bump* Any new development on this? it's been a while and lots happened at Last.FM in the meantime with the new Library and auto-corretion going on. I see there's even a Last.FM node available, any ways to now import playcounts to MM?

Post by m0nkiii » Tue Feb 27, 2007 1:36 pm

Jugdish wrote:Unfortunately, it doesn't look like there's anyway to get ALL the information last.fm has on your track plays.

If you were to use last.fm's web services, you will only be able to get playcounts for your top 50 most-played tracks. And if you want the timestamp each track was played as well, that information is only available for the last 10 tracks played.

You could get more information (though still limited) if you got the data from your actual last.fm profile rather than through the web services. Playcounts are available for your top 500 most-played tracks, and timestamps for the track plays go back exactly 2 weeks.

If you wanted to be really hardcore (and didn't care about timestamps), you could parse through your weekly charts for every single week and accumulate the track playcounts. But again, the weekly charts are limited to your top 500 most-played tracks, so assuming you never play more than 500 tracks per week you could theoretically get a complete set of playcount info with this method.


Take a look at my site: http://m0nkiii.apakossa.org/Admin/index ... m&id=album
I've parsed through all weeks and put all tracks in a sql database :)

But as you say, no timestamps. But is that a problem. Just set the timestamp to whatever. Tracks after 500 are probably just played once and won't have that big affect anyway. It's the most played tracks you're after.

Top