-1
我有一个图像(我没有数据集)我想训练张量模型, ,这样我就可以使用该模型来快速识别图像。用tensorflow训练您自己的图像?
我已经实现了一个这样的东西,但它不工作:
import tensorflow as tf
filenames = ['pic.jpg']
# step 2
filename_queue = tf.train.string_input_producer(filenames)
# step 3: read, decode and resize images
reader = tf.WholeFileReader()
filename, content = reader.read(filename_queue)
image = tf.image.decode_jpeg(content, channels=3)
image = tf.cast(image, tf.float32)
resized_image = tf.image.resize_images(image, [224, 224])
# step 4: Batching
image_batch = tf.train.batch([resized_image], batch_size=8)
此外,vuforia如何能够只用一个形象这么快认识?我想要在张量流中实现类似的实现