module ‘tensorflow’ has no attribute ‘logging’

tf.logging was for Logging and Summary Operations and in TF 2.0 it has been removed in favor of the open-source absl-py, and to make the main tf.* namespace has functions that will be used more often.

In TF.2 lesser used functions are gone or moved into sub-packages like tf.math

So instead of tf.logging you could:

  • tf_upgrade_v2 will upgrade script and changes tf.logging to tf.compat.v1.logging
  • Python logging module can be used instead
  • Import absl-py library

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)