|
|
@ -599,12 +599,15 @@ def provide_patches(imgs_list_train, segs_list_train, dir_img, dir_seg, dir_flow
|
|
|
|
indexer += 1
|
|
|
|
indexer += 1
|
|
|
|
if brightening:
|
|
|
|
if brightening:
|
|
|
|
for factor in brightness:
|
|
|
|
for factor in brightness:
|
|
|
|
|
|
|
|
try:
|
|
|
|
cv2.imwrite(dir_flow_train_imgs + '/img_' + str(indexer) + '.png',
|
|
|
|
cv2.imwrite(dir_flow_train_imgs + '/img_' + str(indexer) + '.png',
|
|
|
|
(resize_image(do_brightening(dir_img + '/' +im, factor), input_height, input_width)))
|
|
|
|
(resize_image(do_brightening(dir_img + '/' +im, factor), input_height, input_width)))
|
|
|
|
|
|
|
|
|
|
|
|
cv2.imwrite(dir_flow_train_labels + '/img_' + str(indexer) + '.png',
|
|
|
|
cv2.imwrite(dir_flow_train_labels + '/img_' + str(indexer) + '.png',
|
|
|
|
resize_image(cv2.imread(dir_of_label_file), input_height, input_width))
|
|
|
|
resize_image(cv2.imread(dir_of_label_file), input_height, input_width))
|
|
|
|
indexer += 1
|
|
|
|
indexer += 1
|
|
|
|
|
|
|
|
except:
|
|
|
|
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
|
if binarization:
|
|
|
|
if binarization:
|
|
|
|
cv2.imwrite(dir_flow_train_imgs + '/img_' + str(indexer) + '.png',
|
|
|
|
cv2.imwrite(dir_flow_train_imgs + '/img_' + str(indexer) + '.png',
|
|
|
|