tf.app.run()AttributeError:模块'tensorflow'没有属性'app'

时间:2020-06-27 22:03:10

标签: python tensorflow

我将tf.app.run()更改为tf.compat.v1.run(),但没有帮助。

if __name__ == '__main__':
    # tf.app.run()

    tf.compat.v1.run()
AttributeError: module 'tensorflow._api.v2.compat.v1' has no attribute 'run'
Process finished with exit code 1

0 个答案:

没有答案