Skip to content

Commit

Permalink
Merge pull request #1003 from ReallyNiceGuy/master
Browse files Browse the repository at this point in the history
ENH: Default scan_rate to target_scan_rate
  • Loading branch information
zssherman authored Jul 26, 2021
2 parents 3c1024e + 13df628 commit d921640
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pyart/aux_io/gamic_hdf5.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,20 +236,21 @@ def read_gamic(filename, field_names=None, additional_metadata=None,

# scan_rate
scan_rate = filemetadata('scan_rate')
scan_rate['data'] = target_scan_rate['data']
if scan_type == 'ppi':
azs_names = ['az_speed', 'azimuth_speed']
azs_name = azs_names[0]
for azs_name in azs_names:
if gfile.is_field_in_ray_header(azs_name):
scan_rate['data'] = gfile.ray_header(azs_name, 'float32')
break
scan_rate['data'] = gfile.ray_header(azs_name, 'float32')
elif scan_type == 'rhi':
els_names = ['el_speed', 'elevation_speed']
els_name = els_names[0]
for els_name in els_names:
if gfile.is_field_in_ray_header(els_name):
scan_rate['data'] = gfile.ray_header(els_name, 'float32')
break
scan_rate['data'] = gfile.ray_header(els_name, 'float32')
else:
scan_rate = None

Expand Down

0 comments on commit d921640

Please sign in to comment.