Commit 69def1b5 authored by Andrey Filippov's avatar Andrey Filippov

next version

parent f964c4f2
This diff is collapsed.
......@@ -199,8 +199,6 @@ def getMoreFiles(fpaths,rslt):
print_time("Done")
rslt.append(dataset)
#from http://warmspringwinds.github.io/tensorflow/tf-slim/2016/12/21/tfrecords-guide/
def read_and_decode(filename_queue):
reader = tf.TFRecordReader()
......@@ -262,8 +260,6 @@ def extend_img_to_clusters(datasets_img,radius):
rec['gt_ds'] = add_neibs(add_margins(rec['gt_ds'].reshape((height,width,-1)), radius, np.nan), radius).reshape((num_tiles,-1))
pass
def reformat_to_clusters(datasets_data):
cluster_size = (2 * CLUSTER_RADIUS + 1) * (2 * CLUSTER_RADIUS + 1)
# Reformat input data
......@@ -302,7 +298,6 @@ TILE_SIZE = TILE_SIDE* TILE_SIDE # == 81
rec['target_disparity'] = target_disparity.reshape((target_disparity.shape[0],-1))
rec['gt_ds'] = gt_ds.reshape((gt_ds.shape[0],-1))
def replace_nan(datasets_data):
cluster_size = (2 * CLUSTER_RADIUS + 1) * (2 * CLUSTER_RADIUS + 1)
# Reformat input data
......@@ -353,7 +348,6 @@ def shuffle_chunks_in_place(datasets_data, tiles_groups_per_chunk):
ds['target_disparity'] = ds['target_disparity'].reshape((chunks_per_file,-1))[permut].reshape((groups_per_file,-1))
ds['gt_ds'] = ds['gt_ds']. reshape((chunks_per_file,-1))[permut].reshape((groups_per_file,-1))
def _setFileSlot(train_next,files):
train_next['files'] = files
train_next['slots'] = min(train_next['files'], MAX_FILES_PER_GROUP)
......@@ -377,8 +371,6 @@ def replaceDataset(datasets_data, new_dataset, nset, period, findx):
datasets_data[findx]['gt_ds'] [nset::period] = new_dataset['gt_ds']
def zip_lvar_hvar(datasets_all_data, del_src = True):
# cluster_size = (2 * CLUSTER_RADIUS + 1) * (2 * CLUSTER_RADIUS + 1)
# Reformat input data
......@@ -416,7 +408,6 @@ def reduce_tile_size(datasets_data, num_tile_layers, reduced_tile_side):
[..., offs:offs+reduced_tile_side, offs:offs+reduced_tile_side].
reshape(-1,num_tile_layers*reduced_tile_side*reduced_tile_side))
def result_npy_to_tiff(npy_path, absolute, fix_nan):
"""
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment