Create Last.fm collages
Project description
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
Options
Entity values
"album", "artist", "track"
Period values
"7day", "1month", "3month", "6month", "12month", "overall"
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(entity="album", username="username", cols=5, rows=5, period="7day")
image.save("5x5 album collage.png", "png")
# Or just call the method directly
image = collage_generator.generate_top_albums_collage(username="username", cols=5, rows=5, period="7day")
image.save("5x5 album collage.png", "png")
License
Authors
Project details
Release history Release notifications | RSS feed
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.4.1.tar.gz
(409.3 kB
view hashes)
Built Distribution
Close
Hashes for lastfmcollagegenerator-0.4.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9f6b21a6e07679bbbc111a33d4ec0366eaa77199d595cc7ece98f1105a5b473f |
|
MD5 | 6d8241ea385c2ff7dd967a2ace8693db |
|
BLAKE2b-256 | 6e180f3c12e39526070508e613cd3fa9f860829d72a792f413e97be0cfeb0b7b |
Close
Hashes for lastfmcollagegenerator-0.4.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 07edb9c566c78986f1eaffd2b4b787e198a342e400e4344bb469b92730c164a7 |
|
MD5 | c1071937ae28a270f11f371b3d376b5b |
|
BLAKE2b-256 | 9f68f99c32e2017624f7bcde60e08b03b0cd2d03113f48c613b0de9338d2c6e3 |