Skip to content

Conversation

Sebastian-Larsson
Copy link
Collaborator

@Sebastian-Larsson Sebastian-Larsson commented May 7, 2025

The existing code used assertions to validate slicing parameters (e.g., size must be positive and within dimension limits). This has been changed to raise ValueError with descriptive error messages to provide clearer feedback and robustness for invalid inputs when using aten.slice_copy.Tensor.

cc @digantdesai @freddan80 @per @zingo @oscarandersson8218

The existing code used assertions to validate slicing parameters (e.g.,
size must be positive and within dimension limits). This has been
changed to raise ValueError with descriptive error messages to provide
clearer feedback and robustness for invalid inputs when using
aten.slice_copy.Tensor.

Signed-off-by: Sebastian Larsson <sebastian.larsson@arm.com>
Change-Id: If09bbe2e9e2b0fb1ddbfb3cd64ff2aa99f0dffe4
@Sebastian-Larsson Sebastian-Larsson added partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm ciflow/trunk topic: not user facing labels May 7, 2025
Copy link

pytorch-bot bot commented May 7, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/10748

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 New Failure

As of commit 1e5c141 with merge base 1984c5f (image):

NEW FAILURE - The following job has failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label May 7, 2025
@Sebastian-Larsson
Copy link
Collaborator Author

CI failure ".github/workflows/build-presets.yml (gh)" seems unrelated. I see it in other PRs as well

@zingo zingo merged commit cebe051 into pytorch:main May 7, 2025
175 checks passed
jhelsby pushed a commit to jhelsby/executorch that referenced this pull request May 9, 2025
…ytorch#10748)

The existing code used assertions to validate slicing parameters (e.g.,
size must be positive and within dimension limits). This has been
changed to raise ValueError with descriptive error messages to provide
clearer feedback and robustness for invalid inputs when using
aten.slice_copy.Tensor.

Signed-off-by: Sebastian Larsson <sebastian.larsson@arm.com>
@Sebastian-Larsson Sebastian-Larsson deleted the slice_assert branch May 15, 2025 12:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ciflow/trunk CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm topic: not user facing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants