def _abspath_no_label_load_file(path, epochs=None, shuffle=True, seed=0):
filename_queue = tf.train.string_input_producer([path],
num_epochs=epochs, shuffle=shuffle, seed=seed)
reader = tf.TextLineReader()
key, value = reader.read(filename_queue)
#image_path, = tf.decode_csv(value, record_defaults=[['']], field_delim=' ')
image_path = value
image_abspath = image_path
image_content = tf.read_file(image_abspath)
image = decode_image(image_content, channels=3)
image.set_shape([None, None, 3])
imgshape = tf.shape(image)[:2]
return image, imgshape, image_path
评论列表
文章目录