Skip to content

Commit

Permalink
Modified scripts/plot_proftrace.py to use isinstance() format for tes…
Browse files Browse the repository at this point in the history
…ting input types
  • Loading branch information
BrettHoover-NOAA committed Dec 2, 2024
1 parent 48c6335 commit 1fdfefe
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions scripts/plot_proftrace.py
Original file line number Diff line number Diff line change
Expand Up @@ -297,13 +297,13 @@ def collect_statistics(setdict):
# entries in a list
# if they are not a list, assert them as a list
it = sd['it']
it = [it] if type(it) != list else it
it = [it] if not isinstance(it, list) else it
use = sd['use']
use = [use] if type(use) != list else use
use = [use] if not isinstance(use, list) else use
typ = sd['typ']
typ = [typ] if type(typ) != list else typ
typ = [typ] if not isinstance(typ, list) else typ
styp = sd['styp']
styp = [styp] if type(styp) != list else styp
styp = [styp] if not isinstance(styp, list) else styp
# extract variable from gdas
stat = gdas.extract(var) # t, uv, q, etc.
# date it obs use
Expand Down

0 comments on commit 1fdfefe

Please sign in to comment.