pytorch / executorch

On-device AI across mobile, embedded and edge for PyTorch
https://pytorch.org/executorch/
Other
2.21k stars 368 forks source link

[pybind] Do not set output data pointer if the output is memory planned #6841

Open larryliu0820 opened 1 week ago

larryliu0820 commented 1 week ago

Summary

This is the same logic in method.cpp:set_output_data_ptr() but add the check in pybindings.cpp to avoid excessive logging and failure.

[method.cpp:941] Output 0 is memory planned, or is a constant. Cannot override         the existing data pointer.

Test plan

Pending

pytorch-bot[bot] commented 1 week ago

:link: Helpful Links

:test_tube: See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/6841

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

:heavy_exclamation_mark: 1 Active SEVs

There are 1 currently active SEVs. If your PR is affected, please view them below:

:x: 1 New Failure

As of commit 08cb16aad312b249493d17211050b99defb834e3 with merge base 9393b8c03d5b43289724e08c40bff0f025d072ab (image):

NEW FAILURE - The following job has failed:

* [Lint / lintrunner / linux-job](https://hud.pytorch.org/pr/pytorch/executorch/6841#32959018798) ([gh](https://github.com/pytorch/executorch/actions/runs/11828617015/job/32959018798)) `>>> Lint for extension/pybindings/pybindings.cpp:`

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