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

snapshot..

parent aebe68f2
Branches
No related tags found
No related merge requests found
...@@ -69,12 +69,14 @@ if KERNEL_SIZE == 3: ...@@ -69,12 +69,14 @@ if KERNEL_SIZE == 3:
slc_y = slice(2, 132) slc_y = slice(2, 132)
slc_x_2 = slice(1, 134, 2) slc_x_2 = slice(1, 134, 2)
slc_y_2 = slice(1, 134, 2) slc_y_2 = slice(1, 134, 2)
x_128 = slice(3, 131)
y_128 = slice(3, 131)
t = np.arange(1, 66, 0.5)
s = np.arange(1, 66, 0.5)
x_2 = np.arange(67) x_2 = np.arange(67)
y_2 = np.arange(67) y_2 = np.arange(67)
t = np.arange(0, 67, 0.5)
s = np.arange(0, 67, 0.5)
x_k = slice(1, 131)
y_k = slice(1, 131)
x_128 = slice(3, 131)
y_128 = slice(3, 131)
elif KERNEL_SIZE == 5: elif KERNEL_SIZE == 5:
slc_x = slice(3, 135) slc_x = slice(3, 135)
slc_y = slice(3, 135) slc_y = slice(3, 135)
...@@ -274,6 +276,7 @@ class SRCNN: ...@@ -274,6 +276,7 @@ class SRCNN:
tmp = np.where(tmp > 1.0, 1.0, tmp) tmp = np.where(tmp > 1.0, 1.0, tmp)
tmp = np.where(np.isnan(tmp), 0, tmp) tmp = np.where(np.isnan(tmp), 0, tmp)
tmp = resample_2d_linear(x_2, y_2, tmp, t, s) tmp = resample_2d_linear(x_2, y_2, tmp, t, s)
tmp = tmp[y_k, x_k]
data_norm.append(tmp) data_norm.append(tmp)
# --------- # ---------
data = np.stack(data_norm, axis=3) data = np.stack(data_norm, axis=3)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment