Uh oh!
There was an error while loading. Please reload this page.
Allow StridedMemoryView to be constructed from dlpacks type code - #1623
Conversation
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
StridedMemoryView to be constructed from dlpacks type code/home/wangm/.pixi/bin/pixi shell --manifest-path /home/wangm/numba-cuda-fp8/pixi.toml --environment cu-13-0-py312StridedMemoryView to be constructed from dlpacks type codeUh oh!
There was an error while loading. Please reload this page.
cpcloud
left a comment
There was a problem hiding this comment.
Looks good except for the torch testing input.
| try: | ||
| import torch | ||
| except ImportError: | ||
| torch = None |
There was a problem hiding this comment.
This should really use pytest.importorskip inside your test. The current pattern is definitely an anti-pattern.
There was a problem hiding this comment.
I think this one is fine, since it matches the style in this file (and a few other places).
There was a problem hiding this comment.
Can probably leave a TODO here for a general refactoring.
There was a problem hiding this comment.
Definitely an anti pattern to address. We shouldn't just keep accumulating them. Not blocking.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
leofang
commented
Feb 18, 2026
@isVoid CuPy v14.0.0 is out and we are preparing to release cuda.core v0.6.0. Let's try to squeeze this in! |
Auto-sync is disabled for ready for review pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
UPDATE: Done. Just one more thing - I need to push some documentation addition. |
isVoid
commented
Feb 18, 2026
/ok to test 948cb4e |
|
isVoid
commented
Feb 18, 2026
/ok to test 2c746f1 |
isVoid
commented
Feb 18, 2026
/ok to test bcd291d |
Uh oh!
There was an error while loading. Please reload this page.
Depends on NVIDIA/cuda-python#1623 --------- Co-authored-by: Michael Wang <isVoid@users.noreply.github.com> Co-authored-by: Leo Fang <leof@nvidia.com>
Description
closes#1624
Patched dtype handler in
_memoryview.pyxto handle dlpack type code of kDLBfloat. Added tests to construct from an external object (currently, cupy) can communicate via dlpack bfloat16 type code.ml_dtypesis added as an optional dependency, whenml_dtypesisn't present, this code path should gracefully raise with readable error.Note: this still depends on
an unreleasednow released build of cupy (14.0.0). cupy/cupy#9670Checklist