TensorFlow2.0 出现 AttributeError: module 'tensorflow' has no attribute 'python_io'
注:(1)版本升级问题,版本2.0升级问题。 (2)安装文件缺失。参考链接:https://blog.csdn.net/Mint_vip/article/details/100775875
·
注:(1)由于版本升级问题,版本2.0的函数文件路径发生变化。
解决办法:在python前面加上compat.v1.。
修改前:
tf.python_io.TFRecordWriter(filename)
修改后:
tf.compat.v1.python_io.TFRecordWriter(filename)
问题解决。
(2)安装文件缺失。
参考链接:https://blog.csdn.net/Mint_vip/article/details/100775875
更多推荐
所有评论(0)