-
Notifications
You must be signed in to change notification settings - Fork 220
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
Why you need to make divisor 16 when deploying model to mmdeploy #564
Comments
This is because of the characteristics of hardware, like GPU. These hardwares run faster if the dimension of a tensor/matrix is divisible by a constant, like 8, 16, or 32. |
yup. i knew that, and this is what i want. did you just append all zero weight convolutions at the end of the channels? why not just do that before finetuning? becuase i don't think it would be worse and can be optimized by tensorcore when training as well. |
We have two reasons to do that when deploying rather than before finetuning:
You absolutely can pad before finetune, and we also provide the choice for you, please refer to source code |
appreciate for your reply. i need some time to read the code. |
I am now reviewing the code of fisher pruning, and find something interesting (https://github.com/open-mmlab/mmrazor/blob/main/configs/pruning/mmdet/group_fisher/retinanet/group_fisher_act_deploy_retinanet_r50_fpn_1x_coco.py#L60).
Here you gave a divisor 16 when deploying, why you need to do that?
The text was updated successfully, but these errors were encountered: