-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add BasicVSR #245
Add BasicVSR #245
Conversation
Codecov Report
@@ Coverage Diff @@
## master #245 +/- ##
==========================================
+ Coverage 81.31% 81.35% +0.04%
==========================================
Files 156 158 +2
Lines 7503 7719 +216
Branches 1102 1141 +39
==========================================
+ Hits 6101 6280 +179
- Misses 1271 1296 +25
- Partials 131 143 +12
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
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.
Thanks for your contribution! There are two files named basicvsr.py
, how about rename mmedit/models/backbones/sr_backbones/basicvsr.py
as basicvsr_net.py
or others?
Sure, I will change it to |
|
||
def __init__(self, mid_channels=64, num_blocks=30, spynet_pretrained=None): | ||
|
||
super(BasicVSRNet, self).__init__() |
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.
super().__init__()
""" | ||
|
||
def __init__(self, in_channels, out_channels=64, num_blocks=30): | ||
super(ResidualBlocksWithInputConv, self).__init__() |
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.
super().__init__()
""" | ||
|
||
def __init__(self, pretrained): | ||
super(SPyNet, self).__init__() |
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.
init
mmedit/models/restorers/basicvsr.py
Outdated
train_cfg=None, | ||
test_cfg=None, | ||
pretrained=None): | ||
super(BasicVSR, self).__init__(generator, pixel_loss, train_cfg, |
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.
super
mmedit/models/restorers/basicvsr.py
Outdated
self.generator.find_unused_parameters = False | ||
|
||
# count training steps | ||
self.step_counter = train_cfg.get('step_counter', |
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.
Proposal:
Add a TAIL
component to the module, just like backbones and heads, and save step counters there, so that they could be automatically saved and restored.
mmedit/models/restorers/basicvsr.py
Outdated
|
||
# Note: For Vimeo-90K, we use mirror extension. Hence, the output | ||
# sequence has 14 frames. Only center frame is kept for Vimeo-90K. | ||
if output.size(1) == 14: |
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.
I don't think the hard-coded 14 is good
Looks good generally. Some minor comments. |
* Add BasicVSR * fix isort * fix isort * rename to basicvsr_net.py * change step_counter to a key in train_cfg * rename and fix minor bug * rename to BasicVSRNet * Fix init and model
BasicVSR: The Search for Essential Components in Video Super-Resolution and Beyond