Move TorchVision App Demo to `pytorch_android_lite`
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 17.9k
- Forks
- 7.3k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 13
Description
🚀 The feature
Currently we depend our Android Demo app depends on pytorch_android. It's recommended to switch to pytorch_android_lite.
Transitioning to the lite version requires us to update the following things:
- Change the exported file from
frcnn_mnetv3.pttofrcnn_mnetv3.ptl - Export the
fasterrcnn_mobilenet_v3_large_320_fpnmodel using_save_for_lite_interpreter() - Update the dependencies to
org.pytorch:pytorch_android_liteandorg.pytorch:pytorch_android_torchvision_lite - Replace
Module.load()withLiteModuleLoader.load()on the code-base
Motivation, pitch
The recommended dependency for mobile is pytorch_android_lite.
Alternatives
No response
Additional context
There are a few bugs that block this at the moment:
- The release pipeline for
pytorch_androidis buggy. The-SNAPSHOTversion contains only the_litebinaries and there is no snapshots forpytorch_android_lite. - There seems to be a bug on the serialization mechanism that exports the model. See https://github.com/pytorch/pytorch/issues/68536
cc @IvanKobzarev
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the Android Demo, its model-export code, dependency declarations, and uses of Module.load(). Check the release-pipeline and serialization blockers, including issue #68536, before making the transition. Done means the demo exports the .ptl model, uses the lite dependencies and loader, and builds successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, python
- Domain
- machine-learning, mobile-dev
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100