Python 3中的Tensorflow中有日志记录属性的替代品吗



在Python 3中的TensorFlow中使用logging属性时,我收到一个错误,该属性无效
我可以用什么来代替它
错误:

tf.logging.set_verbosity(tf.logging.ERROR)
AttributeError: module 'tensorflow' has no attribute 'logging'

在Tensorflow2中,删除了tf.logging。tf.logging用于抓取和总结。

tf_upgrade_v2将升级脚本并将tf.logging更改为tf.compat.v1.logging

最新更新