Skip to content

Comments

Update dimension valid range to signed integer#738

Merged
fdwr merged 1 commit intowebmachinelearning:mainfrom
philloooo:dimension-range
Jul 24, 2024
Merged

Update dimension valid range to signed integer#738
fdwr merged 1 commit intowebmachinelearning:mainfrom
philloooo:dimension-range

Conversation

@philloooo
Copy link
Contributor

@philloooo philloooo commented Jul 23, 2024

fixes #734

Update valid dimension definition to be in the range of long and greater than 0.

@fdwr @huningxin


Preview | Diff

Copy link
Contributor

@huningxin huningxin left a comment

Choose a reason for hiding this comment

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

LGTM!

@fdwr
Copy link
Collaborator

fdwr commented Jul 24, 2024

It occurs to me the existing verbiage "Implementations may impose a smaller upper bound" technically already covered this case, since CoreML and TFLite impose a smaller bound (2 billion) than the DML EP (4 billion). Though, I'm content with this restriction, since 2 billion is well more than enough for a single dimension (never saw a model that even came close to that in half a decade for a single tensor).

@fdwr fdwr merged commit 71dd440 into webmachinelearning:main Jul 24, 2024
github-actions bot added a commit that referenced this pull request Jul 24, 2024
SHA: 71dd440
Reason: push, by fdwr

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@philloooo philloooo deleted the dimension-range branch August 26, 2024 18:06
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.

Restrict dimensions size to [0, INT32_MAX]

3 participants