Skip to content

Commit

Permalink
Update _sigmetfile.pyx (#1612)
Browse files Browse the repository at this point in the history
add decoding for corrected velocity
  • Loading branch information
gransen312 authored Aug 7, 2024
1 parent c474fa5 commit 4c5686c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pyart/io/_sigmetfile.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -715,6 +715,13 @@ def convert_sigmet_data(data_type, data, nbins):
out[:] = (ndata - 128.) / 127.
mask[ndata == 0] = True

elif data_type_name == 'VELC':
# VELC, 3, Velocity (1 byte)
# 1-byte Corrected Velocity Format, section 4.4.42
out[:] = (ndata - 128.) / 127. *75.
mask[ndata == 0] = True
mask[ndata == 255] = True

elif data_type_name == 'WIDTH':
# WIDTH, 4, Width (1 byte)
# 1-byte Width format, section 4.3.25
Expand Down

0 comments on commit 4c5686c

Please sign in to comment.