-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
[Enhancement] Support hrnet frozen stage #743
Conversation
Codecov Report
@@ Coverage Diff @@
## master #743 +/- ##
==========================================
+ Coverage 85.35% 85.37% +0.02%
==========================================
Files 107 107
Lines 5823 5847 +24
Branches 952 960 +8
==========================================
+ Hits 4970 4992 +22
- Misses 672 673 +1
- Partials 181 182 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
Hi @sshuair |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems that the unittest of HRNet are missing in our original codebase.
We appreciate it a lot if you could add more unittests for HRNet.
@Junjun2016 I will add more HRNet unitest when I am free, but now I am busy at some work. |
@@ -575,6 +607,7 @@ def train(self, mode=True): | |||
"""Convert the model into training mode will keeping the normalization | |||
layer freezed.""" | |||
super(HRNet, self).train(mode) | |||
self._freeze_stages() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move this line inside train()
like resnet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xvjiarui I did not find any difference between the resnet
and hrnet
about self._freeze_stages()
. Could you give more information?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry. My bad, I forgot to expand the collapsed code lines.
* support hrnet frozen stage * support hrnet frozen stage
Motivation
Add new feature to support HRNet frozen stage like ResNet.
Modification
frozen_stages
forHRNet
._freeze_stages
forHRNet
.test_hrnet_backbone
to test the frozen_stages.BC-breaking (Optional)
No.
Use cases (Optional)
Checklist