KEMBAR78
adaptive pooling supports only specifying size in certain dimension by blackyang · Pull Request #3127 · pytorch/pytorch · GitHub
Skip to content

Conversation

@blackyang
Copy link
Contributor

Adaptive pooling supports only specifying size in certain dimensions. For example, we can have:

x = Variable(torch.rand(1,3,10,10))
m = nn.AdaptiveMaxPool2d((5,None))
y=m(x)
y.size()  # torch.Size([1, 3, 5, 10])

This is useful for certain sequence related tasks

@blackyang
Copy link
Contributor Author

blackyang commented Oct 15, 2017

Maybe I should also change docs accordingly if this is merged

@soumith soumith merged commit 3cb3474 into pytorch:master Nov 1, 2017
@soumith
Copy link
Member

soumith commented Nov 1, 2017

if you can, please send a PR to fix the docs. thank you!

@blackyang
Copy link
Contributor Author

@soumith I created a PR #3746 to fix the docs. Do you think it's okay?

@soumith
Copy link
Member

soumith commented Nov 16, 2017

it looks great, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants