Skip to content

Commit

Permalink
fix bug due to missing fzl in some routines
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfidan committed Dec 5, 2023
1 parent 997db1f commit 02aae44
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/pyrad_proc/pyrad/proc/process_echoclass.py
Original file line number Diff line number Diff line change
Expand Up @@ -1622,6 +1622,8 @@ def process_hydroclass(procstatus, dscfg, radar_list=None):

ml_depth = dscfg.get('ml_depth', 0.5)
perturb_ml_depth = dscfg.get('perturb_ml_depth', 0)

freezing_level = None
if 'freezing_level' in dscfg:
freezing_level = dscfg['freezing_level']
elif 'sounding' in dscfg:
Expand Down
4 changes: 4 additions & 0 deletions src/pyrad_proc/pyrad/proc/process_monitoring.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ def process_selfconsistency_kdp_phidp(procstatus, dscfg, radar_list=None):
'Missing data')
return None, None

fzl = None
# determine which freezing level reference
if temp is not None:
if temp in radar.fields:
Expand Down Expand Up @@ -397,6 +398,7 @@ def process_selfconsistency_bias(procstatus, dscfg, radar_list=None):
'Missing data')
return None, None

fzl = None
# determine which freezing level reference
if temp is not None:
if temp in radar.fields:
Expand Down Expand Up @@ -716,6 +718,7 @@ def process_selfconsistency_bias2(procstatus, dscfg, radar_list=None):
'Missing data')
return None, None

fzl = None
# determine which freezing level reference
if temp is not None:
if temp in radar.fields:
Expand Down Expand Up @@ -1064,6 +1067,7 @@ def process_rhohv_rain(procstatus, dscfg, radar_list=None):
warn('Unable to estimate RhoHV in rain. Missing data')
return None, None

fzl = None
# determine which freezing level reference
if temp_field is not None:
if temp_field in radar.fields:
Expand Down
3 changes: 3 additions & 0 deletions src/pyrad_proc/pyrad/proc/process_phase.py
Original file line number Diff line number Diff line change
Expand Up @@ -437,6 +437,7 @@ def process_phidp_kdp_Maesaka(procstatus, dscfg, radar_list=None):
zmax = dscfg.get('Zmax', 40.)
thickness = dscfg.get('ml_thickness', 700.)

fzl = None
# determine which freezing level reference
if temp_field is not None:
if temp_field in radar.fields:
Expand Down Expand Up @@ -622,6 +623,7 @@ def process_phidp_kdp_lp(procstatus, dscfg, radar_list=None):
'Missing data')
return None, None

fzl = None
# determine which freezing level reference
if temp_field is not None:
if temp_field in radar.fields:
Expand Down Expand Up @@ -1166,6 +1168,7 @@ def process_attenuation(procstatus, dscfg, radar_list=None):
return None, None

# determine which freezing level reference
fzl = None
if temp is not None:
if temp in radar.fields:
temp_ref = 'temperature'
Expand Down

0 comments on commit 02aae44

Please sign in to comment.