Skip to content

exercise#1 in the WarmUp  #4

Description

@conlinwang

Dear TAs,
One silly question, from me.
in the WarmUp LeNet

self.conv1 = nn.Conv2d(1, 6, kernel_size=(5,5),stride=1, padding=0)
self.conv2 = nn.Conv2d(6, 16, kernel_size=(5,5),stride=1, padding=0)
self.fc1 = nn.Linear(1644, 120) <---

when I was reading the LeNet paper I thought it was 16* (5*5), because the input data is 32x32
however, I've output the size of from the code and found out the size was
28x28
why is it not 32x32 do datasets.MNIST on PyTorch chop down the size of the datasets.MNIST??
Thank you so much

ref:
(128L, 1L, 28L, 28L)
(128L, 6L, 24L, 24L)
(128L, 6L, 12L, 12L)
(128L, 16L, 8L, 8L)
(128L, 16L, 4L, 4L)
(128L, 256L)
(128L, 120L)
(128L, 84L)
(128L, 10L)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions