使用tensorflow批次的读取预处理之后的文本数据,并将其分为一个迭代器批次:
比如此刻,我有一个处理之后的数据包: data.csv shape =(8,10),其中这个结构中,前五个列为feature...41,42,43,44,45,46,47,48,49,50
51,52,53,54,55,56,57,58,59,60
1,1,1,1,1,2,2,2,2,2
3,3,3,3,3,4,4,4,4,4
现在我需要将其分为4个批次: 也就是每个批次batch的大小为...columns with the specified defaults, which also
# sets the data type for each column
words_size = 5 # 每一行数据的长度...field_delim=',',
record_defaults=[[0] for i in range(words_size * 2)])
batch_size = 2 # 每一个批次的大小...print (i, sess.run([features, label]))
coord.request_stop()
coord.join(threads)
当我们运行的时候