美文网首页
TFRecords注意事项

TFRecords注意事项

作者: yalesaleng | 来源:发表于2018-07-16 17:03 被阅读5次

    注意:
       如果存储为tfrecords格式之前的原始数据类型是np.uint8,
       那么在从tfrecords文件中解码出文件时,
       一定要 img = tf.decode_raw(x, tf.uint8)!!!!
       之后再将 img转化为tf.float32格式输入到网络中(tf的网络模型默认输入是tf.float32格式)

    相关文章

      网友评论

          本文标题:TFRecords注意事项

          本文链接:https://www.haomeiwen.com/subject/fdbbpftx.html