Skip to content
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

Implement CupyArrayContext #251

Open
wants to merge 20 commits into
base: main
Choose a base branch
from
Open

Implement CupyArrayContext #251

wants to merge 20 commits into from

Conversation

matthiasdiener
Copy link
Collaborator

@matthiasdiener matthiasdiener commented Feb 16, 2024

Please squash

@matthiasdiener matthiasdiener self-assigned this Feb 16, 2024
@matthiasdiener matthiasdiener force-pushed the cupyactx branch 4 times, most recently from ce508df to 55b4cbf Compare February 16, 2024 23:03
Co-authored-by: Kaushik Kulkarni <[email protected]>
Comment on lines 1254 to 1256
if isinstance(actx, CupyArrayContext):
pytest.skip("CupyArrayContext does not support object arrays")

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@inducer: We had briefly discussed adding support for object arrays via a wrapper (?), but I'm not sure how that should look like.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out this was caused by the incomplete array container support, fixed in e9c42dd. Thanks to @majosm for the help!

Comment on lines +242 to +244
d = cupy.cuda.runtime.getDeviceProperties(cupy.cuda.Device())
name = d["name"].decode("utf-8")
return f"<CupyArrayContext> on {cupy.cuda.Device()}:{name}"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the only part of the code that give me pause for supporting something like cupy-rocm.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cupy-rocm seems to be completely out-of-date, so probably no big deal.

@matthiasdiener
Copy link
Collaborator Author

This is ready for a first look @inducer

@matthiasdiener matthiasdiener marked this pull request as ready for review January 31, 2025 22:54
@matthiasdiener
Copy link
Collaborator Author

This is ready for review @inducer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant