Skip to content
Snippets Groups Projects
Commit 3b45c83f authored by tomrink's avatar tomrink
Browse files

snaphot...

parent 6aea0cda
No related merge requests found
...@@ -357,6 +357,9 @@ def compute_and_add_geo_hgt(path_to_amvs, path_to_gfs, amv_source, band='14'): ...@@ -357,6 +357,9 @@ def compute_and_add_geo_hgt(path_to_amvs, path_to_gfs, amv_source, band='14'):
amv_ds = get_datasource(path_to_amvs, amv_source, file_time_span=20, band=band) amv_ds = get_datasource(path_to_amvs, amv_source, file_time_span=20, band=band)
amv_filenames = amv_ds.flist amv_filenames = amv_ds.flist
alt_s = []
prs_s = []
for fname in amv_filenames: for fname in amv_filenames:
print(fname) print(fname)
nom_time = amv_ds.get_datetime(fname).timestamp() nom_time = amv_ds.get_datetime(fname).timestamp()
...@@ -378,8 +381,13 @@ def compute_and_add_geo_hgt(path_to_amvs, path_to_gfs, amv_source, band='14'): ...@@ -378,8 +381,13 @@ def compute_and_add_geo_hgt(path_to_amvs, path_to_gfs, amv_source, band='14'):
temp_prof = temp_prof.values temp_prof = temp_prof.values
temp_prof_s = temp_prof[0, :, :] temp_prof_s = temp_prof[0, :, :]
alt_s = []
for k in range(num_amvs): for k in range(num_amvs):
alt = pressure_to_altitude(amvs_nd[k, amv_pres_idx], None, gfs_press, temp_prof_s[k, :]) amv_press = amvs_nd[k, amv_pres_idx]
alt = pressure_to_altitude(amv_press, None, gfs_press, temp_prof_s[k, :])
alt_s.append(alt.magnitude) alt_s.append(alt.magnitude)
alt_s = np.array(alt_s) prs_s.append(amv_press)
\ No newline at end of file alt_s = np.array(alt_s)
prs_s = np.array(prs_s)
print('Done...')
return prs_s, alt_s
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment