提交 c3b6a0e6 authored 作者: Frederic's avatar Frederic

Fix compute_test_value with DisconnectedType grandient.

上级 a0684973
...@@ -909,6 +909,8 @@ def _populate_grad_dict(var_to_app_to_idx, ...@@ -909,6 +909,8 @@ def _populate_grad_dict(var_to_app_to_idx,
orig_output, new_output_grad = packed orig_output, new_output_grad = packed
if not hasattr(orig_output, 'shape'): if not hasattr(orig_output, 'shape'):
continue continue
if isinstance(new_output_grad.type, DisconnectedType):
continue
for orig_output_v, new_output_grad_v in get_debug_values( for orig_output_v, new_output_grad_v in get_debug_values(
*packed): *packed):
o_shape = orig_output_v.shape o_shape = orig_output_v.shape
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论