Skip to content

Arm backend: Change node.name to buffer name when indexing state_dict #12485

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 16, 2025

Conversation

Sebastian-Larsson
Copy link
Collaborator

@Sebastian-Larsson Sebastian-Larsson commented Jul 15, 2025

Using node.name for indexing state_dict can result in the following:

KeyError: 'b__tensor_constant1'.

Using the following to fetch the buffer name is the correct way to do it:

buffer_name = self.exported_program.graph_signature.inputs_to_buffers[
    node.name
]

cc @digantdesai @freddan80 @per @zingo @oscarandersson8218

Using node.name for indexing state_dict can result in the following:

`KeyError: 'b__tensor_constant1'`.

Using the following to fetch the buffer name is the correct way to do
it:
```
buffer_name = self.exported_program.graph_signature.inputs_to_buffers[
    node.name
]
```

Change-Id: Iea9a672cca921fa523788ed33adaa428035c7619
Signed-off-by: Sebastian Larsson <[email protected]>
@Sebastian-Larsson Sebastian-Larsson added partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm ciflow/trunk release notes: none Do not include this in the release notes labels Jul 15, 2025
Copy link

pytorch-bot bot commented Jul 15, 2025

🔗 Helpful Links

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

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

❌ 1 New Failure, 1 Unrelated Failure

As of commit ade34af with merge base c2d6f3d (image):

NEW FAILURE - The following job has failed:

BROKEN TRUNK - The following job failed but were present on the merge base:

👉 Rebase onto the `viable/strict` branch to avoid these failures

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 Jul 15, 2025
@AdrianLundell AdrianLundell merged commit 07c8f0f into pytorch:main Jul 16, 2025
197 of 199 checks passed
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 release notes: none Do not include this in the release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants