Skip to content

Commit

Permalink
fix: Frontend Failing Test: torch - tensor.torch.Tensor.unique (#28283)
Browse files Browse the repository at this point in the history
  • Loading branch information
ogbanugot authored Feb 14, 2024
1 parent 9e9c086 commit c32c879
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion ivy/functional/backends/torch/set.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def unique_all(
[i[0] for i in sorted(enumerate(values_), key=lambda x: tuple(x[1]))]
)
ivy_torch = ivy.current_backend()
values = ivy_torch.gather(values, sort_idx, axis=axis)
values = values.index_select(dim=axis, index=sort_idx)
counts = ivy_torch.gather(counts, sort_idx)
indices = ivy_torch.gather(indices, sort_idx)
inv_sort_idx = ivy_torch.invert_permutation(sort_idx)
Expand Down
1 change: 1 addition & 0 deletions ivy/functional/frontends/torch/tensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -2242,6 +2242,7 @@ def ne_(self, other):
"float16",
"complex128",
"complex64",
"bool",
)
},
"torch",
Expand Down

0 comments on commit c32c879

Please sign in to comment.