Commit 1c59e4f0 authored by Yuxin Wu's avatar Yuxin Wu

use func.__name__ for unknown layers in argscope patch

parent e57425b9
...@@ -78,7 +78,7 @@ def argscope_mapper(func, log_shape=True): ...@@ -78,7 +78,7 @@ def argscope_mapper(func, log_shape=True):
in_tensor = args[0] in_tensor = args[0]
ctx = get_current_tower_context() ctx = get_current_tower_context()
name = '<unkown>' if 'name' not in kwargs else kwargs['name'] name = func.__name__ if 'name' not in kwargs else kwargs['name']
if log_shape: if log_shape:
if ('tower' not in ctx.ns_name.lower()) or ctx.is_main_training_tower: if ('tower' not in ctx.ns_name.lower()) or ctx.is_main_training_tower:
logger.info('%20s: %20s -> %20s' % logger.info('%20s: %20s -> %20s' %
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment