-
Notifications
You must be signed in to change notification settings - Fork 157
Open
Description
When implementing things for NumPy, I noticed a few things:
- All other structs are also
typedef'd, the new...Versionedis not. - In our discussions at some point we had a large comment in place for how far
DLTensorVersionedis ABI stable. This is missing (i.e. we want everything up to and including the flags to be ABI stable, after that all bets are off for major versions). - When the major version changes, we may need a new struct. I am wondering if it might still make sense to just rip the band-aid off and remove
dl_tensorfrom the...Versionedstruct and introduce a...V1which includes it.
That would make it abundantly clear that you need to cast. If v2 doesn't need a new struct, could make it an alias or just document that?
On the Python side, copy=True and espeically copy=None behavior could be clarified. I did the lazy path in NumPy and just always copied with copy=True.
In very rare cases that might make an array exportable, which isn't without copy=True (due to odd strides).
It may make sense to clarify that copy=None is only required to do copies to make device requests work (if they are supported).
Metadata
Metadata
Assignees
Labels
No labels