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

snapshot...

parent d380bb20
No related branches found
No related tags found
No related merge requests found
......@@ -35,6 +35,7 @@ TRIPLET = False
CONV3D = False
NOISE_TRAINING = False
NOISE_STDDEV = 0.01
img_width = 16
......@@ -244,10 +245,12 @@ class IcingIntensityNN:
data = []
for param in train_params:
nda = self.get_parameter_data(param, nd_idxs, is_training)
if NOISE_TRAINING and is_training:
nda = normalize(nda, param, mean_std_dct, add_noise=True, noise_scale=0.01, seed=42)
else:
nda = normalize(nda, param, mean_std_dct)
# Manual Corruption Process. Better: see use of tf.keras.layers.GaussianNoise
# if NOISE_TRAINING and is_training:
# nda = normalize(nda, param, mean_std_dct, add_noise=True, noise_scale=0.01, seed=42)
# else:
# nda = normalize(nda, param, mean_std_dct)
nda = normalize(nda, param, mean_std_dct)
if DO_ZERO_OUT and is_training:
try:
zero_out_params.index(param)
......@@ -842,6 +845,8 @@ class IcingIntensityNN:
f.close()
def build_model(self):
if NOISE_TRAINING:
self.inputs[0] = tf.keras.layers.GaussianNoise(stddev=NOISE_STDDEV)(self.inputs[0])
flat = self.build_cnn()
# flat_1d = self.build_1d_cnn()
# flat = tf.keras.layers.concatenate([flat, flat_1d, flat_anc])
......
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