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

[Question]Tutorial 5 (JAX) Max-pool branch for inception #131

Open
sy-eng opened this issue Dec 10, 2023 · 2 comments
Open

[Question]Tutorial 5 (JAX) Max-pool branch for inception #131

sy-eng opened this issue Dec 10, 2023 · 2 comments

Comments

@sy-eng
Copy link

sy-eng commented Dec 10, 2023

Thank you for your great tutorials!

I have a question about codes in the cell 11 in Inception_ResNet_DenseNet.ipynb for JAX.

Max-pool branch looks like a 1x1 convolution branch,
because the output of nn.max_pool() is not used.

x_max = nn.max_pool(x, (3, 3), strides=(2, 2))
x_max = nn.Conv(self.c_out["max"], kernel_size=(1, 1), kernel_init=googlenet_kernel_init, use_bias=False)(x)

I guess, here should be :

x_max = nn.max_pool(x, (3, 3), strides=(1, 1))
x_max = nn.Conv(self.c_out["max"], kernel_size=(1, 1), kernel_init=googlenet_kernel_init, use_bias=False)(x_max)

With strides = (2, 2), the feature size gets half of the original, so, the "strides" should be (1,1).

Thank you.

@phlippe
Copy link
Owner

phlippe commented Jan 6, 2024

Hi, thanks for pointing that out! This is indeed a typo and should have used a stride of 1 and x_max as input to the conv. I'll leave this issue open, since we'll need to retrain the models for fixing this. Thanks again :)

@sy-eng
Copy link
Author

sy-eng commented Jan 6, 2024

Thank you for your reply!

I also retrained it and found very little difference between the models with and without pooling layer.
googleNet

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