Skip to main content

Create Last.fm collages

Project description

MIT License

lastfm-collage-generator

Python library to create Last.fm collages from user's top albums.

It supports different configurations like the grid size or the period.

Features

  • Choose the number of rows and columns (for now, up to 5)
  • Choose the period to calculate the top (7day, 1month, 3month, 6month, 12month, overall. Default: 7day)

Installation

Install lastfmcollagegenerator with pip

  pip install lastfmcollagegenerator

Usage/Examples

from lastfmcollagegenerator.collage_generator import CollageGenerator

collage_generator = CollageGenerator(lastfm_api_key="YOUR_API_KEY", lastfm_api_secret="YOUR_API_SECRET")

# Returns a PIL Image object
image = collage_generator.generate_top_albums_collage(username="username", cols=5, rows=5, period="7day")
image.save("5x5 collage.png", "png")

License

MIT

Authors

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lastfmcollagegenerator-0.2.8.tar.gz (408.0 kB view hashes)

Uploaded source

Built Distribution

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page