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

snapshot...

parent 6489f29b
Branches
No related tags found
No related merge requests found
......@@ -71,26 +71,7 @@ def build_conv2d_block(conv, num_filters, activation, block_name, padding='SAME'
class UNET:
def __init__(self, day_night='DAY', l1b_or_l2='both', use_flight_altitude=False, gpu_device=0, datapath=None):
if day_night == 'DAY':
self.train_params_l1b = train_params_l1b_day
self.train_params_l2 = train_params_l2_day
if l1b_or_l2 == 'both':
self.train_params = train_params_l1b_day + train_params_l2_day
elif l1b_or_l2 == 'l1b':
self.train_params = train_params_l1b_day
elif l1b_or_l2 == 'l2':
self.train_params = train_params_l2_day
else:
self.train_params_l1b = train_params_l1b_night
self.train_params_l2 = train_params_l2_night
if l1b_or_l2 == 'both':
self.train_params = train_params_l1b_night + train_params_l2_night
elif l1b_or_l2 == 'l1b':
self.train_params = train_params_l1b_night
elif l1b_or_l2 == 'l2':
self.train_params = train_params_l2_night
def __init__(self):
self.train_data = None
self.train_label = None
......@@ -130,7 +111,6 @@ class UNET:
self.accuracy = None
self.loss = None
self.pred_class = None
self.gpu_device = gpu_device
self.variable_averages = None
self.global_step = None
......@@ -199,13 +179,11 @@ class UNET:
self.DISK_CACHE = False
self.USE_FLIGHT_ALTITUDE = use_flight_altitude
if datapath is not None:
self.DISK_CACHE = False
f = open(datapath, 'rb')
self.in_mem_data_cache = pickle.load(f)
f.close()
# if datapath is not None:
# self.DISK_CACHE = False
# f = open(datapath, 'rb')
# self.in_mem_data_cache = pickle.load(f)
# f.close()
tf.debugging.set_log_device_placement(LOG_DEVICE_PLACEMENT)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment