What does that code snippet signify "tf.logging.set_verbosity(tf.logging.INFO)" in tensorflow code?

The logging level documentation page basically tells you: If you set it to the level as displayed (INFO), then TensorFlow will tell you all messages that have the label INFO (or more critical).

Say you would only be interested in WARN or ERROR, then you could similarly set tf.logging.set_verbosity(tf.logging.WARN)


It is easier to try this yourself. I use Pycharm IDE and it captures the output.

import tensorflow as tf

tf.logging.set_verbosity(tf.logging.DEBUG)
#tf.logging.set_verbosity(tf.logging.INFO) 
# Other settings

tf.logging.debug('Debug')
tf.logging.info('info')
tf.logging.warn('warn')
tf.logging.error('error')
tf.logging.fatal('fatal')