MCPcopy Index your code
hub / github.com/tensorlayer/TensorLayer / log_if

Function log_if

tensorlayer/logging/tl_logging.py:187–190  ·  view source on GitHub ↗

Log 'msg % args' at level 'level' only if condition is fulfilled.

(level, msg, condition, *args)

Source from the content-addressed store, hash-verified

185
186
187def log_if(level, msg, condition, *args):
188 """Log 'msg % args' at level 'level' only if condition is fulfilled."""
189 if condition:
190 vlog(level, msg, *args)
191
192
193def _GetFileAndLine():

Callers 2

log_every_nFunction · 0.85
log_first_nFunction · 0.85

Calls 1

vlogFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…