We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 018c567 commit f7162f8Copy full SHA for f7162f8
sparse/mlir_backend/_array.py
@@ -1,5 +1,6 @@
1
import numpy as np
2
3
+from ._dtypes import DType
4
from .levels import StorageFormat
5
6
@@ -21,7 +22,7 @@ def ndim(self) -> int:
21
22
return len(self.shape)
23
24
@property
- def dtype(self):
25
+ def dtype(self) -> type[DType]:
26
return self._storage.get_storage_format().dtype
27
28
@@ -34,7 +35,7 @@ def _get_mlir_type(self):
34
35
def _to_module_arg(self):
36
return self._storage.to_module_arg()
37
- def copy(self):
38
+ def copy(self) -> "Array":
39
from ._conversions import from_constituent_arrays
40
41
arrs = tuple(arr.copy() for arr in self.get_constituent_arrays())
0 commit comments