Skip to content

Conversation

@GregoryComer
Copy link
Member

@GregoryComer GregoryComer commented Feb 28, 2025

Summary

This PR makes a few minor doc polish changes, such as moving system requirements above installation in getting started, cleaning up some code snippets, using MV2 for the getting started example, and some minor miscellaneous cleanup.

Test plan

Built docs locally to verify the content and formatting of changes.

cc @mergennachin @byjlw

@pytorch-bot
Copy link

pytorch-bot bot commented Feb 28, 2025

🔗 Helpful Links

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

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

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 Feb 28, 2025
@GregoryComer GregoryComer added module: doc Issues related to documentation, both in docs/ and inlined in code triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module release notes: misc Miscellaneous labels Feb 28, 2025
model = MyModel() # The PyTorch model to export
example_inputs = (torch.randn(1,3,64,64),) # A tuple of inputs
model = models.mobilenetv2.mobilenet_v2(weights=MobileNet_V2_Weights.DEFAULT).eval()
sample_inputs = (torch.randn(1, 3, 224, 224), )
Copy link
Contributor

Choose a reason for hiding this comment

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

where is the actual export call?

exported_graph = torch.export.export(model, sample_inputs)

Copy link
Member Author

Choose a reason for hiding this comment

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

It's actually inline in the to_edge_transform_and_lower call. I've been doing that for conciseness and have seen users doing this, but maybe it's better to break out?

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah didn't see it somehow, maybe it's easy to miss.

yeah, at least for examples, and getting started, breaking out could be useful

Copy link
Contributor

@mergennachin mergennachin left a comment

Choose a reason for hiding this comment

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

See inline comments

@GregoryComer GregoryComer merged commit 3ece593 into pytorch:main Feb 28, 2025
6 of 7 checks passed
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. module: doc Issues related to documentation, both in docs/ and inlined in code release notes: misc Miscellaneous triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants