Python matplotlib package Image color scheme

Source: Internet
Author: User

Optional color scheme:

A few of the usual:

Color Map Description
Autumn Red-orange-yellow
Bone Black-White, X-ray
Cool Cyan-Magenta
Copper Black-Copper
Flag Red-white-blue-black
Gray Black-White
Hot Black-red-yellow-white
Hsv HSV color space, red-yellow-green-cyan-blue-magenta-red
Inferno Black-red-yellow
Jet Blue-cyan-yellow-red
Magma Black-red-white
Pink Black-powder-white
Plasma Green-red-yellow
Prism Red-yellow-green-blue-violet-...-Green mode
Spring Magenta-Yellow
Summer Green-Yellow
viridis Blue-green-yellow
Winter Blue-Green

cm= ' spectral ' #hot bone cool copper gray HSV inferno jet Magma pink plasma Summer viridis BWR Ocean Rainbow coolwarm Sp Ectral ........ .........
Norm = Matplotlib.colors.Normalize (Vmin=min, Vmax=max)
Map=plt.imshow (Plt_arr,interpolation= ' nearest ',cmap=cm,norm=norm, origin= ' Upper ') # Plt_arr is the data to be displayed
mydpi=1000
Plt.savefig ("Filename.png", dpi=mydpi, bbox_inches= ' tight ', pad_inches=0) #, bbox_inches= ' tight ' less white area
Plt.show ()

Image example:

Hsv

Hot

Cool

Rainbow

Gist_earth

Python matplotlib package Image color scheme

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.