本文整理汇总了Python中pycam02ucs.cm.viscm.viscm函数的典型用法代码示例。如果您正苦于以下问题:Python viscm函数的具体用法?Python viscm怎么用?Python viscm使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了viscm函数的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: viscm
[ 0.89387855, 0.91384221, 0.38787579],
[ 0.90281044, 0.9152864 , 0.4026516 ],
[ 0.9114428 , 0.91681782, 0.41750661],
[ 0.91979668, 0.91843305, 0.43241222],
[ 0.9278919 , 0.92012856, 0.44734592],
[ 0.93574701, 0.9219008 , 0.46229025],
[ 0.94337929, 0.92374622, 0.47723183],
[ 0.95080035, 0.92566398, 0.49214548],
[ 0.95802315, 0.92765211, 0.50701436],
[ 0.96506661, 0.92970447, 0.52184916],
[ 0.97194366, 0.93181788, 0.53664677],
[ 0.97866617, 0.93398929, 0.55140545],
[ 0.98524501, 0.93621585, 0.56612453],
[ 0.99169013, 0.93849488, 0.58080418]]
test_cm = LinearSegmentedColormap.from_list(__file__, cm_data)
if __name__ == "__main__":
import matplotlib.pyplot as plt
import numpy as np
try:
from pycam02ucs.cm.viscm import viscm
viscm(test_cm)
except ImportError:
print("pycam02ucs not found, falling back on simple display")
plt.imshow(np.linspace(0, 100, 256)[None, :], aspect='auto',
cmap=test_cm)
plt.show()
示例2: viscm
[0.7184095238, 0.7411333333, 0.3904761905],
[0.7524857143, 0.7384, 0.3768142857], [0.7858428571, 0.7355666667,
0.3632714286], [0.8185047619, 0.7327333333, 0.3497904762],
[0.8506571429, 0.7299, 0.3360285714], [0.8824333333, 0.7274333333, 0.3217],
[0.9139333333, 0.7257857143, 0.3062761905], [0.9449571429, 0.7261142857,
0.2886428571], [0.9738952381, 0.7313952381, 0.266647619],
[0.9937714286, 0.7454571429, 0.240347619], [0.9990428571, 0.7653142857,
0.2164142857], [0.9955333333, 0.7860571429, 0.196652381],
[0.988, 0.8066, 0.1793666667], [0.9788571429, 0.8271428571, 0.1633142857],
[0.9697, 0.8481380952, 0.147452381], [0.9625857143, 0.8705142857, 0.1309],
[0.9588714286, 0.8949, 0.1132428571], [0.9598238095, 0.9218333333,
0.0948380952], [0.9661, 0.9514428571, 0.0755333333],
[0.9763, 0.9831, 0.0538]]
parula_map = LinearSegmentedColormap.from_list('parula', data)
# For use of "viscm view"
test_cm = parula_map
if __name__ == "__main__":
import matplotlib.pyplot as plt
import numpy as np
try:
from pycam02ucs.cm.viscm import viscm
viscm(parula_map)
except ImportError:
print("pycam02ucs not found, falling back on simple display")
plt.imshow(np.linspace(0, 100, 256)[None, :], aspect='auto',
cmap=parula_map)
plt.show()