-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Device object and device kwarg
for creation
#156
Comments
That's right. AFAIK the intention is to use |
We first had a separate Device object, but after discussion found that there were too many differences between libraries to make it straightforward/sensible to standardize. For library code, typically what you want to do is:
rather than using an explicit |
Discussion on this API is in gh-96 |
Crystal clear! |
Feel free to reopen if you have further questions on the device aspect, @emcastillo! |
I think we should keep this issue open until we revise the description in question array-api/spec/design_topics/device_support.md Lines 52 to 54 in 0941067
as it wasn't clear to either library developers nor end users what to do. In particular, for CuPy this implies the Device object needs to have a cpu flavor so that we can facilitate host-device transfer, a point I overlooked.
|
Hi,
When reading the section regarding devices, I stumbled upon the following note:
I understood this, as users can never instantiate a
Device
object themselves.But in the paragraph inmediately above there are sentences like:
And both require a
Device
object, that according to the note, can't be directly instantiated, or be obtained from elsewhere than a created array.The text was updated successfully, but these errors were encountered: