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

snapshot...

parent 03c18e27
No related branches found
No related tags found
No related merge requests found
......@@ -8,6 +8,7 @@ import os, datetime
import numpy as np
import pickle
import h5py
import time
LOG_DEVICE_PLACEMENT = False
......@@ -716,13 +717,14 @@ class SRCNN:
LEN_Y, LEN_X = refl.shape
print(LEN_Y, LEN_X)
t0 = time.time()
bt = get_grid_values_all(h5f, 'temp_11_0um_nom')
cld_opd = get_grid_values_all(h5f, 'cld_opd_dcomp')
refl_sub_lo = get_grid_values_all(h5f, 'refl_0_65um_nom_min_sub')
refl_sub_hi = get_grid_values_all(h5f, 'refl_0_65um_nom_max_sub')
refl_sub_std = get_grid_values_all(h5f, 'refl_0_65um_nom_stddev_sub')
t1 = time.time()
print('read data time: ', (t1 - t0))
self.run_inference_(bt, refl_sub_lo, refl_sub_hi, refl_sub_std, cld_opd, LEN_Y, LEN_X)
......@@ -743,6 +745,7 @@ class SRCNN:
# refl_us = normalize(refl_us, 'refl_0_65um_nom', mean_std_dct)
# print('REFL done')
t0 = time.time()
bt = np.where(np.isnan(bt), 0, bt)
bt = bt[slc_y, slc_x]
bt = np.expand_dims(bt, axis=0)
......@@ -770,6 +773,8 @@ class SRCNN:
cld_opd_us = upsample_static(cld_opd, x_2, y_2, t, s, None, None)
cld_opd_us = normalize(cld_opd_us, label_param, mean_std_dct)
print('OPD done')
t1 = time.time()
print('upsample/normalize time: ', (t1 - t0))
data = np.stack([bt_us, refl_sub_lo, refl_sub_hi, refl_sub_std, cld_opd_us], axis=3)
......
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