Skip to content

Use NDArrayDescriptor.resolvingDynamicDimensions instead of modifying NDArrayDescriptor.shape directly#74

Merged
blevine1 merged 1 commit into
apple:mainfrom
blevine1:use-ndarraydescriptor-resolving-dynamic-dimensions
Jul 1, 2026
Merged

Use NDArrayDescriptor.resolvingDynamicDimensions instead of modifying NDArrayDescriptor.shape directly#74
blevine1 merged 1 commit into
apple:mainfrom
blevine1:use-ndarraydescriptor-resolving-dynamic-dimensions

Conversation

@blevine1

@blevine1 blevine1 commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

The intended way to fill in the dynamic dimensions of a dynamic shape NDArrayDescriptor is to use NDArrayDescriptor.resolvingDynamicDimensions(_:), which will check for validity of swapped shaped.

This PR updates to use that API instead of mutating NDArrayDescriptor.shape directly.

@blevine1 blevine1 requested a review from tjia1818 July 1, 2026 19:22
@blevine1 blevine1 force-pushed the use-ndarraydescriptor-resolving-dynamic-dimensions branch from 8866f5c to 8892dcb Compare July 1, 2026 19:43
@blevine1 blevine1 force-pushed the use-ndarraydescriptor-resolving-dynamic-dimensions branch from 8892dcb to 4bd0c6b Compare July 1, 2026 19:58
@blevine1 blevine1 merged commit 78413ae into apple:main Jul 1, 2026
3 checks passed
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.

3 participants