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

snapshot...

parent 055417d6
No related branches found
No related tags found
No related merge requests found
......@@ -397,9 +397,8 @@ class IcingIntensityFCN:
data = np.transpose(data, axes=(1, 2, 0))
data = np.expand_dims(data, axis=0)
# TODO: altitude data will be specified by user at run-time
nda = np.zeros([data.shape[1]*data.shape[2]])
nda[:] = self.flight_level
nda = np.zeros([1])
nda[0] = self.flight_level
nda = tf.one_hot(nda, 5).numpy()
return data, nda
......@@ -445,9 +444,7 @@ class IcingIntensityFCN:
indexes = list(indexes)
dataset = tf.data.Dataset.from_tensor_slices(indexes)
# dataset = dataset.batch(PROC_BATCH_SIZE)
dataset = dataset.map(self.data_function_evaluate, num_parallel_calls=8)
# dataset = dataset.cache()
self.eval_dataset = dataset
def setup_pipeline(self, filename_l1b_trn, filename_l1b_tst, filename_l2_trn, filename_l2_tst, trn_idxs=None, tst_idxs=None, seed=None):
......@@ -990,12 +987,7 @@ class IcingIntensityFCN:
self.reset_test_metrics()
pred_s = []
# for data in self.eval_dataset:
# ds = tf.data.Dataset.from_tensor_slices(data)
# ds = ds.batch(BATCH_SIZE)
# for mini_batch in ds:
# pred = self.model([mini_batch], training=False)
# pred_s.append(pred)
for data in self.eval_dataset:
print(data[0].shape, data[1].shape)
pred = self.model([data])
......
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