Skip to content

Conversation

@metascroy
Copy link
Contributor

Adds ability to specify model_dir to optimum test script. This is convinient if you want the pte file for local debugging. If no model_dir is specified, a temp directory is created.

@pytorch-bot
Copy link

pytorch-bot bot commented Aug 4, 2025

🔗 Helpful Links

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

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

❗ 1 Active SEVs

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

❌ 2 New Failures, 1 Cancelled Job, 1 Unrelated Failure

As of commit 4815b11 with merge base 7750116 (image):

NEW FAILURES - The following jobs have failed:

CANCELLED JOB - The following job was cancelled. Please retry:

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.

@meta-cla meta-cla 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 Aug 4, 2025
@github-actions
Copy link

github-actions bot commented Aug 4, 2025

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

parser.add_argument("--model", type=str, required=True)
parser.add_argument("--recipe", type=str, required=True)
parser.add_argument("--quantize", action="store_true", help="Enable quantization")
parser.add_argument("--model_dir", type=str, required=False)
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit add help?

model_dir=args.model_dir,
recipe=args.recipe,
quantize=args.quantize,
run_only=False,
Copy link
Contributor

Choose a reason for hiding this comment

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

why does this depend on the model_dir type

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It doesn't, I'll remove it

Comment on lines 301 to 305
test_fn(
model_id=model_id,
model_dir=tmp_dir,
recipe=args.recipe,
quantize=args.quantize,
Copy link
Contributor

Choose a reason for hiding this comment

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

de-dup across if/else

@metascroy metascroy merged commit be2b6b5 into main Aug 6, 2025
219 of 223 checks passed
@metascroy metascroy deleted the add-model-dir-arg branch August 6, 2025 17:56
agrima1304 pushed a commit to agrima1304/executorch that referenced this pull request Aug 26, 2025
…pytorch#13116)

Adds ability to specify model_dir to optimum test script. This is
convinient if you want the pte file for local debugging. If no model_dir
is specified, a temp directory is created.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants