Unverified 提交 771ac6c5 authored 作者: imyhxy's avatar imyhxy 提交者: GitHub

Fixed logging level in distributed mode (#4284)

上级 2d990632
...@@ -23,7 +23,6 @@ try: ...@@ -23,7 +23,6 @@ try:
except ImportError: except ImportError:
thop = None thop = None
logging.basicConfig(format="%(message)s", level=logging.INFO)
LOGGER = logging.getLogger(__name__) LOGGER = logging.getLogger(__name__)
...@@ -108,6 +107,7 @@ def profile(input, ops, n=10, device=None): ...@@ -108,6 +107,7 @@ def profile(input, ops, n=10, device=None):
# profile(input, [m1, m2], n=100) # profile over 100 iterations # profile(input, [m1, m2], n=100) # profile over 100 iterations
results = [] results = []
logging.basicConfig(format="%(message)s", level=logging.INFO)
device = device or select_device() device = device or select_device()
print(f"{'Params':>12s}{'GFLOPs':>12s}{'GPU_mem (GB)':>14s}{'forward (ms)':>14s}{'backward (ms)':>14s}" print(f"{'Params':>12s}{'GFLOPs':>12s}{'GPU_mem (GB)':>14s}{'forward (ms)':>14s}{'backward (ms)':>14s}"
f"{'input':>24s}{'output':>24s}") f"{'input':>24s}{'output':>24s}")
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论