Skip to content

Padding in Tensorflow vs Pytorch #17

@zanussbaum

Description

@zanussbaum

Hey I had a quick question regarding padding. I don't have a ton of experience with Pytorch, but as far as I can tell from this, it seems that the layer adds the parameter padding of zeros to each axis of the input.

However, in your implementation, you use padding='same'. In the original implementation in pytorch, the author uses padding=1. I'm under the impression that to get the padding the same, we would need to specify the padding manually in tensorflow.

Am I missing something here where Tensorflow is taking care of something under the hood that I'm not understanding?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions