File tree Expand file tree Collapse file tree 2 files changed +17
-6
lines changed Expand file tree Collapse file tree 2 files changed +17
-6
lines changed Original file line number Diff line number Diff line change @@ -59,8 +59,9 @@ class Info:
59
59
60
60
def __init__ (self ):
61
61
self ._capabilities = {
62
- "boolean_indexing" : True ,
63
- "data_dependent_shapes" : True ,
62
+ "boolean indexing" : True ,
63
+ "data-dependent shapes" : True ,
64
+ "max dimensions" : 64 ,
64
65
}
65
66
self ._all_dtypes = {
66
67
"bool" : dpt .bool ,
@@ -84,11 +85,20 @@ def capabilities(self):
84
85
85
86
Returns a dictionary of ``dpctl``'s capabilities.
86
87
88
+ The dictionary contains the following keys:
89
+ ``"boolean indexing"``:
90
+ boolean indicating ``dpctl``'s support of boolean indexing.
91
+ Value: ``True``
92
+ ``"data-dependent shapes"``:
93
+ boolean indicating ``dpctl``'s support of data-dependent shapes.
94
+ Value: ``True``
95
+ ``max dimensions``:
96
+ integer indication the maximum array dimension supported by ``dpctl``.
97
+ Value: ``64``
98
+
87
99
Returns:
88
100
dict:
89
101
dictionary of ``dpctl``'s capabilities
90
- - ``"boolean_indexing"``: bool
91
- - ``data_dependent_shapes"``: bool
92
102
"""
93
103
return self ._capabilities .copy ()
94
104
Original file line number Diff line number Diff line change @@ -79,8 +79,9 @@ def test_array_api_inspection_devices():
79
79
80
80
def test_array_api_inspection_capabilities ():
81
81
capabilities = dpt .__array_namespace_info__ ().capabilities ()
82
- assert capabilities ["boolean_indexing" ]
83
- assert capabilities ["data_dependent_shapes" ]
82
+ assert capabilities ["boolean indexing" ]
83
+ assert capabilities ["data-dependent shapes" ]
84
+ assert capabilities ["max dimensions" ] == 64
84
85
85
86
86
87
def test_array_api_inspection_default_dtypes ():
You can’t perform that action at this time.
0 commit comments