擅长:python、mysql、java
<p><a href="https://www.tensorflow.org/api_docs/python/tf/io/FixedLenFeature" rel="noreferrer">tf.FixedLenFeature()</a>用于读取固定大小的数据数组。数据的形状应该预先定义。将解析函数更新为</p>
<pre><code>def parse(tfrecord):
return tf.parse_single_example(tfrecord, features={
'label': tf.FixedLenFeature([3], tf.int64, default_value=[0,0,0]),
'test': tf.FixedLenFeature([3], tf.float32, default_value=[0.0, 0.0, 0.0]),
})
</code></pre>
<p>应该做这项工作。</p>