Closed
Description
如下图所示
_InstanceNormBase 的 self.scale 可以为 None 的,但是如果其他报错栈需要调用 extra_repr() 这个函数,就会报错 AttributeError: 'NoneType' object has no attribute 'shape'
因为在 extra_repr() 里面要打印 self.scale.shape[0], 那当 self.scale 为 None 时就会报错
复现对齐需要,此处 self.scale 必须为 None, 报错是调用 remove_weight_norm() 的时候 InstanceNorm1D 的对象由于没有 wight_norm , 可能就调用了 extra_repr(),然后报错
Metadata
Metadata
Assignees
Labels
No labels