Skip to content
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

SE param is not used in OSA module #10

Open
tkhe opened this issue May 12, 2020 · 2 comments
Open

SE param is not used in OSA module #10

tkhe opened this issue May 12, 2020 · 2 comments

Comments

@tkhe
Copy link

tkhe commented May 12, 2020

From OSA stage I noticed that SE param can be changed to False in some cases, e.g. block_per_stage != 1. I guess it means the following OSA module should not include SE module.

if block_per_stage != 1:
SE = False
module_name = f"OSA{stage_num}_1"
self.add_module(
module_name, _OSA_module(in_ch, stage_ch, concat_ch, layer_per_block, module_name, SE, depthwise=depthwise)
)

But it seems that the SE param defined in OSA module is never used, so SE module will be applied in every OSA module.

class _OSA_module(nn.Module):
def __init__(
self, in_ch, stage_ch, concat_ch, layer_per_block, module_name, SE=False, identity=False, depthwise=False
):

Is it a bug? or just I misunderstood it?

@gau-nernst
Copy link

I notice this also. timm only applies SE in the last block. I didn't see the papers mentioned any of these.

https://github.com/rwightman/pytorch-image-models/blob/07eb2f12005f75be3ed6c2394f3512e7a8ac640a/timm/models/vovnet.py#L244-L256

Have you figured out whether it is a bug?

@gau-nernst
Copy link

Seems like SE is only applied to stage 2 and 3, since they have only 1 block? Still, it is pretty strange

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants