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

minor...

parent 4e863faf
No related branches found
No related tags found
No related merge requests found
......@@ -311,16 +311,16 @@ def make_for_full_domain_predict(clvrx_file, name_list=l1b_ds_list):
h5f = h5py.File(clvrx_file, 'r')
grd_dct = {name: [] for name in name_list}
grd_dct = {name: None for name in name_list}
cnt_a = 0
for didx, ds_name in enumerate(name_list):
gvals = get_grid_values_all(h5f, ds_name)
if gvals is not None:
grd_dct[ds_name].append(gvals)
grd_dct[ds_name] = gvals
cnt_a += 1
if cnt_a > 0 and cnt_a != len(ds_list):
if cnt_a > 0 and cnt_a != len(name_list):
raise GenericException('weirdness')
grd_dct_n = {name: [] for name in name_list}
......@@ -331,14 +331,19 @@ def make_for_full_domain_predict(clvrx_file, name_list=l1b_ds_list):
i_0 = 0
j_0 = 0
for didx, ds_name in enumerate(ds_list):
for didx, ds_name in enumerate(name_list):
print(ds_name)
for j in range(4, n_y-4, 1):
j_ul = j_0 + j * w_y
for i in range(4, n_x-4, 1):
i_ul = i_0 + i * w_x
grd_dct_n[ds_name].append(grd_dct[ds_name][j_ul:j_ul+w_y, i_ul:i_ul+w_x])
return grd_dct_n
grd_dct = {name: None for name in name_list}
for didx, ds_name in enumerate(name_list):
grd_dct[ds_name] = np.concatenate(grd_dct_n[ds_name])
return grd_dct
def analyze(ice_dct, no_ice_dct):
......
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