diff --git a/modules/util/gfs_reader.py b/modules/util/gfs_reader.py index a54a6080725d1f95a903640076ef0eca8caf1eab..9522750bd0ff1e568dc1c57f287cbcf241c38295 100644 --- a/modules/util/gfs_reader.py +++ b/modules/util/gfs_reader.py @@ -140,14 +140,8 @@ def get_time_interpolated_layer(ds_0, ds_1, time_0, time_1, time, fld_name, pres def get_time_interpolated_layer_s(ds_0, ds_1, time_0, time_1, time, fld_name_s, press, lon_lo, lon_hi, lat_lo, lat_hi): - lyr_s_0 = [] - lyr_s_1 = [] - for fld_name in fld_name_s: - lyr = get_horz_layer(ds_0, fld_name, press, lon_lo, lon_hi, lat_lo, lat_hi) - lyr_s_0.append(lyr) - - lyr = get_horz_layer(ds_1, fld_name, press, lon_lo, lon_hi, lat_lo, lat_hi) - lyr_s_1.append(lyr) + lyr_s_0 = get_horz_layer_s(ds_0, fld_name_s, press, lon_lo, lon_hi, lat_lo, lat_hi) + lyr_s_1 = get_horz_layer_s(ds_1, fld_name_s, press, lon_lo, lon_hi, lat_lo, lat_hi) lyr = xr.concat([lyr_s_0, lyr_s_1], 'time') lyr = lyr.assign_coords(time=[time_0, time_1])