Skip to content

Code Question about: input the final conv-layer output to the linear layer #71

@ShengzheXu

Description

@ShengzheXu

Great code guys! Can I ask a question at this code?
https://github.com/locuslab/TCN/blob/master/TCN/adding_problem/model.py#L17

Usually when I implement CNN-series model, the calculation of the last layer CNN dimension was always a problem.

In your code, Line17, it looks the final linear layer just catches a part of the conv-layer output. Is this understanding correct? Does it ignore many other parameters that in the conv-layer output?

What shocks me is, when I test such implementation on other traditional CNN models, they also works. (I mean just use like self.linear(y1[:, :, -1])) Does this mean the task is simple for the designed CNN because we just dropped a lot of neurons in it?

Will be highly appreciated if someone could advice.

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