Revamping our Quantized models docs
See original GitHub issueWe’re re-writing our models docs to make them clearer, simpler, and to properly document the upcoming multi-weight API. This issue is about adding docs for the Quantized classification models.
Our latest new docs are currently here (this link is likely outdated by the time you look at it, but it doesn’t matter; the skeleton is there). We created a separate section that will eventually be merged into the main one. We have documented a few models, but most of them are still missing. The list of models that still need docs is listed below. If you’d like to participate, please comment below with a message saying “I’m working on XYZ” where XYZ is a model, so that others don’t pick the same as you do. To keep things simple, please submit one PR per model, but feel free to contribute more than one model.
How to write docs for a model
Note: below are detailed instructions. This makes it look more complicated than it actually is. Don’t be scared!
A great place to start is to look a the changes in this PR that documents SqueezeNet. You’ll need to do exactly the same for your model:
- Create a new
.rst
file in https://github.com/pytorch/vision/tree/main/docs/source/models. The file should look like this, with a link to the original paper, and a list of the corresponding model builders. It should also mention the base model class and link to the.py
file where it is defined. - Update the list in https://github.com/pytorch/vision/blame/main/docs/source/models_new.rst to link to this new file (without the
.rst
suffix). Please keep the list alphabetically sorted - Update the docstring of each new model builder, similarly to this one.
- there is a 1:1 mapping between a model builder and a Weight enum. For example, the docstring of squeezenet1_0 makes direct references to SqueezeNet1_0_Weights. For Quantized models there might be more weights for a single model builder, check the link above!
- don’t forget the autoclass directive in the docstring. This will auto-generate documentation for the Weight enums. You don’t need to understand how this is done, but if you’re curious, it’s done here.
To build the docs locally, please look at our contributing guide. You won’t need to worry about the gallery example, so always use make html-noplot
instead of make html
to save time.
Please don’t hesitate to ping us if you need any help / guidance or if you have any question!
Quantized models that need docs are:
- Inception - https://github.com/pytorch/vision/pull/6005
- MobileNetV2 - https://github.com/pytorch/vision/pull/6004
- MobileNetV3 - https://github.com/pytorch/vision/pull/6016
- ResNet - https://github.com/pytorch/vision/pull/6012
- ResNeXt - https://github.com/pytorch/vision/pull/6032
- ShuffleNetV2 - https://github.com/pytorch/vision/pull/6028
Issue Analytics
- State:
- Created a year ago
- Comments:15 (15 by maintainers)
@frgfm This the open-source version of music chairs: Ping more contributors than tickets and see what happens. 😄 😆
In all seriousness thanks for responding and no worries. We are very lucky to have you all supporting us like this. We got many more improvements on the pipeline coming up that we could use your help. Thanks for the support!
Wow I think we are done! Thanks a lot for the help!