-
Notifications
You must be signed in to change notification settings - Fork 583
Update MemoryPlanning Verifier to only assume model has user input if it has at least one tensor input #10617
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
base: main
Are you sure you want to change the base?
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/10617
Note: Links to docs will display an error until the docs builds have been completed. ❌ 10 New Failures, 2 Unrelated FailuresAs of commit 19371e3 with merge base f7c906f ( NEW FAILURES - The following jobs have failed:
FLAKY - The following job failed but was likely due to flakiness present on trunk:
BROKEN TRUNK - The following job failed but was 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. |
Didn't find following labels among repository labels: Release notes: exir |
@pytorchbot label "release notes: exir" |
Started CI (Need to do for new, external contributions). Rebase please. Also marked it as Ready to signal reviewers that it's, well, ready for a review. Thanks for the contribution. Welcome to Executorch 😊 |
Thank you, I just rebased. I also fixed the linting issues which the CI tests identified. [Sorry, I messed this up, hence the subsequent force-push.] |
… it has at least one tensor input MemoryPlanning verifier currently blows up if all the user inputs are prims. This change means its helper function _do_user_inputs_exist returns false if all its inputs are prims. It only returns true if at least one input is a tensor.
fbb360a
to
19371e3
Compare
cc @JacobSzwejbka can you take a look? 🙏 |
@JacobSzwejbka gentle ping |
Fixes #10522
Summary
MemoryPlanning verifier currently blows up if all the user inputs are prims. #10522 suggested:
This PR implements this suggestion, with accompanying unit tests.
_do_user_inputs_exist
now returns True if it has at least one tensor input, and False otherwise.Test plan
Added unit tests to
test_memory_planning.py
and ran them withPlease note you must comment out the line 69 from
/pytest.ini
for this to work:On my machine, I also had to comment out line 60 from
test_memory_planning.py
for the test to run without errors.[The tests I wrote aren't dependent on this library.]