Add array API inspection utilities to dpctl.tensor#1469
Conversation
This inspection utility is coming to the array API specification in the near future
|
View rendered docs @ https://intelpython.github.io/dpctl/pulls/1469/index.html |
|
Array API standard conformance tests for dpctl=0.15.1dev1=py310ha25a700_4 ran successfully. |
| def devices(self): | ||
| return dpctl.get_devices() |
There was a problem hiding this comment.
It is possible to run in an environment where CUDA device is available, but dpctl was not compiled to offload to NVidia GPUs.
Perhaps we should thin this list by ensuring that we can create an dpt.arange for this device and cache that list.
It does not need to be done in this PR though
|
Array API standard conformance tests for dpctl=0.15.1dev1=py310ha25a700_6 ran successfully. |
|
The |
Disallows dtypes for `kind` kwarg in __array_namespace_info__().dtypes Removes `float16` from dtypes listed by __array_namespace_info__ as per spec Permits dpctl.tensor.Device objects in device keyword arguments in array API inspection utilities
13a4262 to
412692a
Compare
|
Array API standard conformance tests for dpctl=0.15.1dev1=py310ha25a700_16 ran successfully. |
oleksandr-pavlyk
left a comment
There was a problem hiding this comment.
Thank you @ndgrigorian
This pull request proposes implementing
dpctl.tensor.__array_namespace_info__, an inspection utility coming soon to the array API specification.In addition, this PR adds an
__array_api_version__attribute as per the specification and experimentally removes the--ciflag from array API testing.