首页 > 解决方案 > 我该如何解决 flags=tensorflow.app.flags 错误

问题描述

import tensorflow as tf
flags = tf.app.flags

AttributeError:模块“tensorflow”没有属性“app”

标签: python-3.7

解决方案


尝试使用:import tensorflow.compat.v1 as tf


推荐阅读