Package: metalmaps
Metalmaps - Heavy Metal and Classic Rock Album Art Inspired Matplotlib ColormapsEver wanted to make your python plots more metal? Fear not, now you can!metalmapsdelivers heavy metal and classic rock album art inspiredmatplotlibcolormaps!Visit thegalleryfor a
comprehensive picture.ContentsInstallationUsageExamplesNoteContributingAuthors, License, CreditsInstallationInstall this package via pip:pipinstallmetalmapsAlternatively, grab the source fromgithub.UsageTo use these, you can import them and use them
with matplotlib as you would with any other color map.frommetalmapsimportblack_sabbathfrommatplotlib.pyplotimportimshowfromnumpyimportrandomimshow(random.rand(128,128),cmap=black_sabbath)The color maps can also be accessed in matplotlib using strings
by prefixingmetalmaps, e.g.importmetalmapsimshow(random.rand(128,128),cmap="metalmaps.red")Using a colormap as default line colors in plotsIt's possible to replace the default matplotlib color cycle with one
provided by this package. To achieve this, call the providedmetalmaps.set_color_cycle()function, and pass the colormap you
want as the argument, e.g:importmetalmapsmetalmaps.set_color_cycle(metalmaps.reign_in_blood)For example, this codefrommatplotlibimportpyplotaspltimportnumpyasnpimportmetalmapsmetalmaps.set_color_cycle(metalmaps.reign_in_blood)x=np.linspace(0,1.4,200)defy(x,phi):returnnp.sin(1.2*np.pi*(x+0.25)-0.1*phi)plt.figure()foriinrange(10):labelname="C"+str(i)plt.plot(x,y(x,i),linewidth=5,label=labelname)plt.legend(ncols=2)plt.tight_layout()plt.savefig("my_figure.png")results in the following figure:where we didn't have to specify the different colors each time we
calledplot().ExamplesThis package currently includes 30 colormaps:Animals (Pink Floyd)The Apostasy (Behemoth)Ashes of the Wake (Lamb of God)Black Sabbath (Black Sabbath)The Blues Brothers (The Blues Brothers)Blues Pills (Blues Pills)Cosmo's Factory (Creedence Clearwater Revival)Deep Purple in Rock (Deep Purple)The Dethalbum (Dethklok)Fear of the Dark (Iron Maiden)From Mars to Sirius (Gojira)Hybrid Theory (Linkin Park)Hypnotize (System of a Down)In Utero (Nirvana)L.A. Woman (The Doors)L'enfant Sauvage (Gojira)London Calling (The Clash)Master of Puppets (Metallica)Made in Japan (Deep Purple)Meteora (Linkin Park)The Number of the Beast (Iron Maiden)obZen (Meshuggah)Overkill (Motörhead)Painkiller (Judas Priest)Paranoid (Black Sabbath)Powerslave (Iron Maiden)Rage Against The Machine (Rage Against The Machine)Reign in Blood (Slayer)Ride the Lightning (Metallica)Rock 'n' Roll (Motörhead)Screaming for Vengeance (Judas Priest)South of Heaven (Slayer)The Hunter (Mastodon)The Rise and Fall of Ziggy Stardust and the Spiders From Mars (David Bowie):exclamation:  For a full gallery, visithttps://mladenivkovic.github.io/metalmaps/metalmaps.htmlHere are some examples:Black Sabbath (Black Sabbath)Deep Purple in Rock (Deep Purple)From Mars To Sirius (Gojira)Master of Puppets (Metallica)obZen (Meshuggah)Overkill (Motörhead)Painkiller (Judas Priest)Paranoid (Black Sabbath)The Hunter (Mastodon)NoteOf course, these aren't necessarily designed to be colorblind
friendly, or perceptually uniform, so use them with caution.
They are fun though. To underline how much you shouldnotuse these in a real scientific publication (apart from
perhaps qualitative imaging), the lightness values are shown
below.For quantitative comparisons, please ensure that you use a
perceptually uniform colour map (see e.g. those available
directly throughmatplotlib).ContributingYes please! It would be grand to collect even more album art colormaps.Intstructions:generate your color palette any way you please, and add it tocolors.pyinstantiate the matplotlib colormap in__init__.pyadd your addition to the album lists inREADME.mdand__init__.pysubmit your merge request???profit!Authors, License, CreditsCreditsAll of this was inspired by (and shamelessly copied from) Josh Borrow'sswiftascmaps.Image credits:The "Kelvin-Helmholtz" data used in the plots below were generated usingmesh-hydro.The "EAGLE" data used in the plots below were obtained from theswiftsimrepository.The "NGC" data used in the plots below were originally obtained fromflickr, credits toJudy Schmidt. I modified the image later to normalize the pixel values to be able to demonstrate the colormaps as above.LicenseLicense: LGPLv3Authors and ContributorsMladen Ivkovic, Josh Borrow