Add several speedup examples#3880
Conversation
|
The file model_speedup.py can't be moved directly to the new folder speedup since
|
| NanoDet model can be installed from https://github.com/RangiLyu/nanodet.git | ||
| """ | ||
|
|
||
| cfg_path = r"nanodet/config/nanodet-RepVGG-A0_416.yml" |
There was a problem hiding this comment.
It is a little strange that user has to install model from other repo for running example. If this model is not very complicated, can we add it into our model compression model files so that user can run it directly.
There was a problem hiding this comment.
no need to put their code into our repo. but we can provide concrete commands about how to prepare the code in the comment
| not_safe = not_safe_to_prune(model, dummy_input) | ||
| cfg_list = [] | ||
| for name, module in model.named_modules(): | ||
| if name in not_safe: |
There was a problem hiding this comment.
maybe we can leverage "exclude" here in the config, @J-shang
There was a problem hiding this comment.
Yes, exclude is much more elegant.
Add a few common detection model examples (if the model written by the user fails to speedup, he/she can refer to the repo we gave).