Skip to content

Commit

Permalink
Removed redundant asdtype function call
Browse files Browse the repository at this point in the history
  • Loading branch information
oleksandr-pavlyk committed Nov 7, 2023
1 parent ff9b5eb commit ca2c6aa
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions dpctl/tensor/_reduction.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,12 @@ def _reduction_over_axis(
res_shape = res_shape + (1,) * red_nd
inv_perm = sorted(range(nd), key=lambda d: perm[d])
res_shape = tuple(res_shape[i] for i in inv_perm)
return dpt.astype(
dpt.full(
res_shape,
_identity,
dtype=dtype,
usm_type=res_usm_type,
sycl_queue=q,
),
res_dt,
return dpt.full(
res_shape,
_identity,
dtype=res_dt,
usm_type=res_usm_type,
sycl_queue=q,
)
if red_nd == 0:
return dpt.astype(x, res_dt, copy=False)
Expand Down

0 comments on commit ca2c6aa

Please sign in to comment.