Skip to content
Snippets Groups Projects
Commit 96b15a53 authored by Bing Gong's avatar Bing Gong
Browse files

Update era5_dataset.py

parent 5eb86d15
Branches
Tags
Loading
Pipeline #66602 passed
__email__ = "b.gong@fz-juelich.de"
__author__ = "Bing Gong, Scarlet Stadtler,Michael Langguth"
......@@ -180,6 +179,7 @@ class ERA5Dataset(object):
dataset = dataset.apply(tf.contrib.data.shuffle_and_repeat(buffer_size =1024, count = self.num_epochs))
else:
dataset = dataset.repeat(self.num_epochs)
if self.mode == "val": dataset = dataset.repeat(20)
num_parallel_calls = None if shuffle else 1
dataset = dataset.apply(tf.contrib.data.map_and_batch(
parser, batch_size, drop_remainder=True, num_parallel_calls=num_parallel_calls))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment