Skip to content

Commit

Permalink
Update _creation_functions.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Illviljan committed Sep 1, 2024
1 parent dc070d7 commit 29fb043
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xarray/namedarray/_array_api/_creation_functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ def empty_like(
device: _Device | None = None,
) -> NamedArray[_ShapeType, _DType]:
xp = _get_data_namespace(x)
_data = xp.empty(x._data, dtype=dtype, device=device)
_data = xp.empty_like(x._data, dtype=dtype, device=device)
return x._new(data=_data)


Expand Down

0 comments on commit 29fb043

Please sign in to comment.