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

Add StochasticDepth implementation #4301

Merged
merged 11 commits into from
Aug 20, 2021

Conversation

datumbox
Copy link
Contributor

Fixes #4298

Copy link
Member

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @datumbox ! I made a brief review with some questions, but this looks good

test/test_ops.py Outdated Show resolved Hide resolved
test/test_ops.py Outdated Show resolved Hide resolved
torchvision/ops/stochastic_depth.py Show resolved Hide resolved
torchvision/ops/stochastic_depth.py Outdated Show resolved Hide resolved
Copy link
Member

@fmassa fmassa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thanks a lot!

I have some small comments, let me know what you think. None of those are merge-blocking, so I'm approving it.

Also, I think you need to add an entry in https://github.com/pytorch/vision/blob/master/docs/source/ops.rst for it to appear in the documentation

torchvision/ops/stochastic_depth.py Outdated Show resolved Hide resolved
torchvision/ops/stochastic_depth.py Outdated Show resolved Hide resolved
torchvision/ops/stochastic_depth.py Outdated Show resolved Hide resolved
@datumbox
Copy link
Contributor Author

Thanks both for the fast review. I believe I addressed all comments. I'll merge after the tests pass.

@datumbox datumbox merged commit ef177c5 into pytorch:master Aug 20, 2021
@datumbox datumbox deleted the ops/stochastic_depth branch August 20, 2021 13:15
facebook-github-bot pushed a commit that referenced this pull request Aug 26, 2021
Summary:
* Adding operator.

* Adding tests

* switching order of `p` and `mode`.

* Remove seed setting.

* Replace stats import with pytest.importorskip.

* Fix doc

* Apply suggestions from code review

* Fixing indentation.

* Adding operator in the documentation.

* Fixing lint

Reviewed By: fmassa

Differential Revision: D30525891

fbshipit-source-id: da8300c8428efa8f74d79ae06c19ea2e040c88c9

Co-authored-by: Francisco Massa <fvsmassa@gmail.com>
Co-authored-by: Francisco Massa <fvsmassa@gmail.com>
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.

Implement a Stochastic Depth operator
4 participants