From be35ac8c9ac862e7760afb69cc2617907e515a94 Mon Sep 17 00:00:00 2001 From: yuzheng Date: Thu, 9 Feb 2023 16:28:24 +0800 Subject: [PATCH] Solve the problem of colormap registration error, rename from 'pyart_' to 'copy_pyart_' --- pycwr/draw/colormap/cm.py | 2 +- pycwr/draw/colormap/cm_colorblind.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pycwr/draw/colormap/cm.py b/pycwr/draw/colormap/cm.py index 6d55c43..dcaa35e 100644 --- a/pycwr/draw/colormap/cm.py +++ b/pycwr/draw/colormap/cm.py @@ -156,7 +156,7 @@ def _generate_cmap(name, lutsize): if name in ["ref", "vel"]: matplotlib.cm.register_cmap(name="CN_"+name, cmap=cmap) else: - full_name = 'pyart_' + name + full_name = 'copy_pyart_' + name matplotlib.cm.register_cmap(name=full_name, cmap=cmap) hid_colors = ['LightBlue', 'MediumBlue', 'DarkOrange', 'LightPink', diff --git a/pycwr/draw/colormap/cm_colorblind.py b/pycwr/draw/colormap/cm_colorblind.py index de3c2f7..8a7d4ff 100644 --- a/pycwr/draw/colormap/cm_colorblind.py +++ b/pycwr/draw/colormap/cm_colorblind.py @@ -66,5 +66,5 @@ def _generate_cmap(name, lutsize): # register the colormaps so that can be accessed with the names pyart_XXX for name, cmap in cmap_d.items(): - full_name = 'pyart_' + name + full_name = 'copy_pyart_' + name mpl.cm.register_cmap(name=full_name, cmap=cmap)