Skip to content
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

[microTVM] Update tutorials #13845

Merged
merged 6 commits into from
Jan 27, 2023
Merged

Conversation

mehrdadh
Copy link
Member

This PR updates microTVM tutorials to use updated APIs.
It also adds an ordering to the tutorials that are useful for first time users.
RVM tutorial is also removed as it is not supported anymore.

@tvm-bot
Copy link
Collaborator

tvm-bot commented Jan 26, 2023

Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.

Generated by tvm-bot

@mehrdadh mehrdadh requested review from gromero and guberti and removed request for gromero January 26, 2023 00:04
@mehrdadh mehrdadh force-pushed the micro/update_tutorials branch from 8dc572f to fdbdc87 Compare January 26, 2023 00:40
Copy link
Member

@guberti guberti left a comment

Choose a reason for hiding this comment

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

LGTM - thanks for updating these tutorials!

"""Intentionally simple function for making Targets for microcontrollers.
If you need more complex arguments, one should call target.micro directly. Note
that almost all, but not all, supported microcontrollers are Arm-based."""
if platform == "crt":
return tvm.target.target.micro("host")

Copy link
Member

Choose a reason for hiding this comment

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

Can we throw a better error if platform is not "crt" and board is None?

Copy link
Member Author

Choose a reason for hiding this comment

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

added, thanks!

target = tvm.target.target.micro("host")
# To use physical hardware, replace `board` with another physical micro target, e.g. `nrf5340dk_nrf5340_cpuapp`
# or `mps2_an521` and change the platform type to Zephyr.
# See more more target examples in micro_train.py and micro_tflite.py tutorials.
Copy link
Member

Choose a reason for hiding this comment

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

Can we mention these tutorials in text instead of in a code comment? That way we can add clickable links.

Copy link
Member Author

Choose a reason for hiding this comment

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

good catch, fixed it

@mehrdadh mehrdadh requested a review from guberti January 26, 2023 23:54
@mehrdadh mehrdadh merged commit c2cc019 into apache:main Jan 27, 2023
@mehrdadh mehrdadh deleted the micro/update_tutorials branch January 27, 2023 22:13
fzi-peccia pushed a commit to fzi-peccia/tvm that referenced this pull request Mar 27, 2023
This PR updates microTVM tutorials to use updated APIs.
It also adds an ordering to the tutorials that are useful for first time users.
RVM tutorial is also removed as it is not supported anymore.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants