mirror of https://github.com/Jittor/Jittor
sqr()
This commit is contained in:
parent
5bcfe0db60
commit
7db591ef0a
|
@ -186,7 +186,7 @@ def norm(x, k, dim):
|
||||||
if k==1:
|
if k==1:
|
||||||
return x.abs().sum(dim)
|
return x.abs().sum(dim)
|
||||||
if k==2:
|
if k==2:
|
||||||
return (x**2).sum(dim).sqrt()
|
return x.sqr().sum(dim).sqrt()
|
||||||
Var.norm = norm
|
Var.norm = norm
|
||||||
|
|
||||||
origin_reshape = reshape
|
origin_reshape = reshape
|
||||||
|
|
Loading…
Reference in New Issue