@@ -250,7 +250,7 @@ def plot_map(pixel_dict, plot_info, map_info, track_dict):
250250
251251 # Set up figure
252252 mpl .rcParams ['font.size' ] = fontsize
253- mpl .rcParams ['font.family' ] = 'Helvetica'
253+ # mpl.rcParams['font.family'] = 'Helvetica'
254254 fig = plt .figure (figsize = figsize , dpi = 200 )
255255 gs = gridspec .GridSpec (1 ,2 , height_ratios = [1 ], width_ratios = [1 ,0.03 ])
256256 gs .update (wspace = 0.05 , hspace = 0.05 , left = 0.1 , right = 0.9 , top = 0.92 , bottom = 0.08 )
@@ -374,13 +374,13 @@ def work_for_time_loop(datafile, track_dict, map_info, plot_info, config):
374374 map_info ['subset' ] = subset
375375
376376 # Make dilation structure (larger values make thicker outlines)
377- # perim_thick = 1
378- # dilationstructure = np.zeros((perim_thick+1,perim_thick+1), dtype=int)
379- # dilationstructure[1:perim_thick, 1:perim_thick] = 1
380- # dilationstructure = generate_binary_structure(2,1)
381377 perim_width = plot_info ['perim_width' ]
382- dilationstructure = np .zeros ((perim_width + 1 ,perim_width + 1 ), dtype = int )
383- dilationstructure [1 :perim_width , 1 :perim_width ] = 1
378+ if perim_width > 1 :
379+ dilationstructure = np .zeros ((perim_width + 1 ,perim_width + 1 ), dtype = int )
380+ dilationstructure [1 :perim_width , 1 :perim_width ] = 1
381+ else :
382+ dilationstructure = generate_binary_structure (2 ,1 )
383+ # import pdb; pdb.set_trace()
384384
385385 # Data variable names
386386 field_varname = config ["field_varname" ]
@@ -483,25 +483,26 @@ def work_for_time_loop(datafile, track_dict, map_info, plot_info, config):
483483 figsize = [10 , 10 ]
484484
485485 # Specify plotting info
486- # cmap = 'RdBu_r', # colormap
487- # levels = np.arange(-4, 4.01, 0.2), # shading levels
488- # cbticks = np.arange(-4, 4.01, 1), # colorbar ticks
489- # cblabels = 'Z500 Anomaly (m$^{2}$ s$^{-1}$)', # colorbar label
490- cmap = 'gist_ncar' # colormap
491- levels = np .arange (0 , 70.01 , 5 ) # shading levels
492- cbticks = np .arange (0 , 70.01 , 10 ) # colorbar ticks
493- cblabels = 'Reflectivity (dBZ)' # colorbar label
486+ cmap = 'RdBu_r' # colormap
487+ levels = np .arange (- 4 , 4.01 , 0.2 ) # shading levels
488+ cbticks = np .arange (- 4 , 4.01 , 1 ) # colorbar ticks
489+ cblabels = 'Z500 Anomaly (m$^{2}$ s$^{-1}$)' # colorbar label
490+ # cmap = 'gist_ncar' # colormap
491+ # levels = np.arange(0, 70.01, 5) # shading levels
492+ # cbticks = np.arange(0, 70.01, 10) # colorbar ticks
493+ # cblabels = 'Reflectivity (dBZ)' # colorbar label
494494 plot_info = {
495495 'fontsize' : 13 , # plot font size
496496 'cmap' : cmap ,
497497 'levels' : levels ,
498498 'cbticks' : cbticks ,
499499 'cblabels' : cblabels ,
500- 'remove_oob_low' : True , # mask out-of-bounds low values (< min(levels))
500+ 'remove_oob_low' : False , # mask out-of-bounds low values (< min(levels))
501501 'remove_oob_high' : False , # mask out-of-bounds high values (> max(levels))
502502 'marker_size' : 10 , # track symbol marker size
503503 'tracknumber_fontsize' : 10 ,
504- 'perim_width' : 6 , # width of the track feature perimeter (number of pixels)
504+ # 'perim_width': 6, # width of the track feature perimeter (number of pixels)
505+ 'perim_width' : 1 , # width of the track feature perimeter (number of pixels)
505506 'trackpath_linewidth' : 1.5 , # track path line width
506507 'trackpath_color' : 'blueviolet' , # track path color
507508 'map_edgecolor' : 'gray' , # background map edge color
@@ -521,7 +522,7 @@ def work_for_time_loop(datafile, track_dict, map_info, plot_info, config):
521522 'lonv' : lonv ,
522523 'latv' : latv ,
523524 'draw_border' : True ,
524- 'draw_state' : True ,
525+ 'draw_state' : False ,
525526 }
526527
527528 # Track stats file
0 commit comments