-
Notifications
You must be signed in to change notification settings - Fork 661
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 pixelshufflev2 module #5383
Conversation
YongtaoShi
commented
Jul 5, 2021
•
edited
Loading
edited
|
||
.. math:: | ||
H_{out} = H_{in} \times \text{upscale_factor} | ||
H_{out} = H_{in} \times \text{h_upscale_factor} |
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.
好像截图的docs上公示显示格式有点问题
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.
是这一行有问题吗?我还没找到。。
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.
我看.. math::写了3次,要不试试只写一次?
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.
哦哦,好
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.
已修改
@@ -36,20 +38,21 @@ class PixelShuffle(Module): | |||
by Shi et. al (2016) for more details. | |||
|
|||
Args: | |||
upscale_factor (int): factor to increase spatial resolution by | |||
h_upscale_factor (int): factor to increase height spatial resolution by |
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.
upscale_factor参数不应该去掉吧,这个PixelShufflev2功能是PixelShufflev的超集,应该保留upscale_factor,默认和pytorch对齐,h_upscale_factor、w_upscale_factor可以设置optianal,都传了,表示使用v2版本
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.
意思是总共3个参数吗?但是使用v2版本需要传3个参数,就有点奇怪了。
现在的逻辑是如果只传入h_upscale_factor,默认w_upscale_factor=h_upscale_factor,对于用户来讲是对齐的,只是变量名字有点区别。
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.
嗯,我感觉已有的变量名字需要完全对齐,多出来的增量的是可以接受的
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.
意思是upscale_factor参数至少不应该去掉
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.
好的
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.
已修改