From 4fb9ddf33241ab3ff409ed9c1f3104a72dc4bf9c Mon Sep 17 00:00:00 2001 From: Brian-Jamison <58485074+Brian-Jamison@users.noreply.github.com> Date: Tue, 10 Sep 2024 12:57:56 -0600 Subject: [PATCH] Changes to RRFS lwtp plot. (#246) * Changing AKRange subdomain for Alaska. * Adding a new plot, which is an amalgamation of a new field (lightning) and 1h total precip. * Some changes made for lwtp plot: removed lower precip contour levels. --- adb_graphics/default_specs.yml | 4 ++-- adb_graphics/specs.py | 10 ++++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/adb_graphics/default_specs.yml b/adb_graphics/default_specs.yml index 6ebdc77..ba24f04 100644 --- a/adb_graphics/default_specs.yml +++ b/adb_graphics/default_specs.yml @@ -1115,9 +1115,9 @@ ltng: # Lightning unit: strikes / hr lwtp: # Lightning with total precip sfc: - clevs: [0.002, 0.01, 0.05, 0.1, 0.25, 0.50, 0.75, 1.0, 2.0] + clevs: [0.25, 0.50, 0.75, 1.0, 2.0] cmap: gist_ncar - colors: pcp_colors + colors: pcp_colors_high contours: ltng_sfc: colors: black diff --git a/adb_graphics/specs.py b/adb_graphics/specs.py index f0abd3b..256ecf7 100644 --- a/adb_graphics/specs.py +++ b/adb_graphics/specs.py @@ -303,6 +303,16 @@ def pcp_colors(self) -> np.ndarray: ([25, 50, 60, 70, 80, 85, 90, 115]) return np.concatenate((grays, ncar)) + @property + def pcp_colors_high(self) -> np.ndarray: + + ''' High values color map for Hourly Precipitation ''' + + grays = cm.get_cmap('Greys', 2)([0]) + ncar = cm.get_cmap(self.vspec.get('cmap'), 128) \ + ([70, 80, 85, 90, 115]) + return np.concatenate((grays, ncar)) + @property def pmsl_colors(self) -> np.ndarray: