Skip to content

Instantly share code, notes, and snippets.

@cossatot
Created July 27, 2016 15:41
Show Gist options
  • Save cossatot/6fd455d6a2e0e1fdb8ed547dd2176eae to your computer and use it in GitHub Desktop.
Save cossatot/6fd455d6a2e0e1fdb8ed547dd2176eae to your computer and use it in GitHub Desktop.
New Python perceptually-uniform colormaps as color ramps for QGIS
<!DOCTYPE qgis_style>
<qgis_style version="0">
<symbols/>
<colorramps>
<colorramp type="gradient" name="Magma">
<prop k="color1" v="0,0,3,255"/>
<prop k="color2" v="251,252,191,255"/>
<prop k="stops" v="0.04;4,4,21,255:0.08;14,10,42,255:0.12;26,16,65,255:0.16;40,17,89,255:0.20;57,15,110,255:0.23;74,16,121,255:0.27;90,21,126,255:0.31;105,28,128,255:0.35;121,34,129,255:0.39;137,40,129,255:0.43;153,45,127,255:0.47;169,50,124,255:0.51;185,55,120,255:0.55;202,62,114,255:0.59;217,70,106,255:0.62;230,81,98,255:0.66;240,96,93,255:0.70;247,113,91,255:0.74;251,132,96,255:0.78;253,151,104,255:0.82;254,170,116,255:0.86;254,188,130,255:0.90;253,207,146,255:0.94;253,225,163,255:0.98;252,243,181,255"/>
</colorramp>
<colorramp type="gradient" name="Inferno">
<prop k="color1" v="0,0,3,255"/>
<prop k="color2" v="252,254,164,255"/>
<prop k="stops" v="0.04;37,5,145,255:0.08;56,4,153,255:0.12;73,2,159,255:0.16;89,1,164,255:0.20;104,0,167,255:0.23;120,1,168,255:0.27;134,7,166,255:0.31;149,17,161,255:0.35;162,28,154,255:0.39;174,39,145,255:0.43;185,51,136,255:0.47;195,62,127,255:0.51;205,73,117,255:0.55;214,85,109,255:0.59;222,96,100,255:0.62;229,108,91,255:0.66;236,120,83,255:0.70;242,133,74,255:0.74;247,146,65,255:0.78;250,160,57,255:0.82;253,175,49,255:0.86;253,190,41,255:0.90;252,206,37,255:0.94;248,223,36,255:0.98;242,240,38,255"/>
</colorramp>
<colorramp type="gradient" name="Plasma">
<prop k="color1" v="12,7,134,255"/>
<prop k="color2" v="239,248,33,255"/>
<prop k="stops" v="0.04;37,5,145,255:0.08;56,4,153,255:0.12;73,2,159,255:0.16;89,1,164,255:0.20;104,0,167,255:0.23;120,1,168,255:0.27;134,7,166,255:0.31;149,17,161,255:0.35;162,28,154,255:0.39;174,39,145,255:0.43;185,51,136,255:0.47;195,62,127,255:0.51;205,73,117,255:0.55;214,85,109,255:0.59;222,96,100,255:0.62;229,108,91,255:0.66;236,120,83,255:0.70;242,133,74,255:0.74;247,146,65,255:0.78;250,160,57,255:0.82;253,175,49,255:0.86;253,190,41,255:0.90;252,206,37,255:0.94;248,223,36,255:0.98;242,240,38,255"/>
</colorramp>
<colorramp type="gradient" name="Viridis">
<prop k="color1" v="68,1,84,255"/>
<prop k="color2" v="253,231,36,255"/>
<prop k="stops" v="0.04;71,15,98,255:0.08;72,29,111,255:0.12;71,42,121,255:0.16;69,54,129,255:0.20;65,66,134,255:0.23;60,77,138,255:0.27;55,88,140,255:0.31;50,98,141,255:0.35;46,108,142,255:0.39;42,118,142,255:0.43;38,127,142,255:0.47;35,137,141,255:0.51;31,146,140,255:0.55;30,155,137,255:0.59;32,165,133,255:0.62;40,174,127,255:0.66;53,183,120,255:0.70;69,191,111,255:0.74;89,199,100,255:0.78;112,206,86,255:0.82;136,213,71,255:0.86;162,218,55,255:0.90;189,222,38,255:0.94;215,226,25,255:0.98;241,229,28,255"/>
</colorramp>
</colorramps>
</qgis_style>
@megies
Copy link

megies commented Jul 10, 2017

Thanks a bunch for this, @cossatot! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment