diff --git a/ivy/functional/frontends/torch/linalg.py b/ivy/functional/frontends/torch/linalg.py index 34bbedd006e56..0174959d032b6 100644 --- a/ivy/functional/frontends/torch/linalg.py +++ b/ivy/functional/frontends/torch/linalg.py @@ -233,6 +233,8 @@ def norm(input, ord=None, dim=None, keepdim=False, *, dtype=None, out=None): elif dim is None and ord is None: input = ivy.flatten(input) ret = ivy.vector_norm(input, axis=0, keepdims=keepdim, ord=2) + elif dim != None and ord is None: + ret = ivy.vector_norm(input, axis=dim, keepdims=keepdim, ord=2) elif isinstance(dim, int): ret = ivy.vector_norm(input, axis=dim, keepdims=keepdim, ord=ord) elif isinstance(dim, tuple) and len(dim) <= 2: