fix typos
This commit is contained in:
parent
2dce0887b3
commit
fb49c1e77d
|
@ -26,7 +26,7 @@ def summary(layer: nn.Layer):
|
||||||
print("layer has {} parameters, {} elements.".format(num_params,
|
print("layer has {} parameters, {} elements.".format(num_params,
|
||||||
num_elements))
|
num_elements))
|
||||||
|
|
||||||
def gradien_norm(layer: nn.Layer):
|
def gradient_norm(layer: nn.Layer):
|
||||||
grad_norm_dict = {}
|
grad_norm_dict = {}
|
||||||
for name, param in layer.state_dict().items():
|
for name, param in layer.state_dict().items():
|
||||||
if param.trainable:
|
if param.trainable:
|
||||||
|
|
Loading…
Reference in New Issue