浏览代码

[skip ci] reformatting log message

/bug-failed-api-check
Anupam Bhatnagar 5 年前
当前提交
6b7b27c7
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. 3
      ml-agents/mlagents/logging_util.py

3
ml-agents/mlagents/logging_util.py


def create_logger(name, log_level):
date_format = "%Y-%m-%d %H:%M:%S"
log_format = "%s %(asctime)s %(levelname)s [%(filename)s:%(lineno)d] %(message)s" % hvd.rank()
horovod_worker = "worker-%s " % str(hvd.rank())
log_format = horovod_worker + "%(asctime)s %(levelname)s [%(filename)s:%(lineno)d] %(message)s"
logging.basicConfig(level=log_level, format=log_format, datefmt=date_format)
logger = logging.getLogger(name=name)
正在加载...
取消
保存