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
Use new_empty in dropout #72078
Use new_empty in dropout #72078
Conversation
CI Flow Status⚛️ CI FlowRuleset - Version:
|
🔗 Helpful links
💊 CI failures summary and remediationsAs of commit d716eef (more details on the Dr. CI page): 💚 💚 Looks good so far! There are no failures yet. 💚 💚 This comment was automatically generated by Dr. CI (expand for details).Please report bugs/suggestions to the (internal) Dr. CI Users group. |
@samdow has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Summary: This will be needed by functorch to have the expected behavior of randomness: Dropout generates a tensor of the right size and then calls `bernoulli_` on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created as `empty_like` but this one just creates `empty` because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls`_dropout_impl` here (not in native_functions.yaml) This shouldn't change the behavior outside of functorch Pull Request resolved: #72078 Reviewed By: zou3519 Differential Revision: D33898338 Pulled By: samdow fbshipit-source-id: 9d9ed59d138d732d9647b2771ccf2ea97cffae1c
Summary: This will be needed by functorch to have the expected behavior of randomness: Dropout generates a tensor of the right size and then calls `bernoulli_` on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created as `empty_like` but this one just creates `empty` because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls`_dropout_impl` here (not in native_functions.yaml) This shouldn't change the behavior outside of functorch Pull Request resolved: #72078 Reviewed By: zou3519 Differential Revision: D33898338 Pulled By: samdow fbshipit-source-id: 9d9ed59d138d732d9647b2771ccf2ea97cffae1c (cherry picked from commit e51cf3e)
Hey samdow. You merged this PR, but no release notes category and topic labels were added. The list of valid release and topic labels is available https://github.com/pytorch/pytorch/labels?q=release+notes+or+topic |
Summary: This will be needed by functorch to have the expected behavior of randomness: Dropout generates a tensor of the right size and then calls `bernoulli_` on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created as `empty_like` but this one just creates `empty` because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls`_dropout_impl` here (not in native_functions.yaml) This shouldn't change the behavior outside of functorch Pull Request resolved: pytorch/pytorch#72078 Reviewed By: zou3519 Differential Revision: D33898338 Pulled By: samdow fbshipit-source-id: 9d9ed59d138d732d9647b2771ccf2ea97cffae1c (cherry picked from commit e51cf3e)
Summary: This will be needed by functorch to have the expected behavior of randomness: Dropout generates a tensor of the right size and then calls `bernoulli_` on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created as `empty_like` but this one just creates `empty` because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls`_dropout_impl` here (not in native_functions.yaml) This shouldn't change the behavior outside of functorch Pull Request resolved: pytorch/pytorch#72078 Reviewed By: zou3519 Differential Revision: D33898338 Pulled By: samdow fbshipit-source-id: 9d9ed59d138d732d9647b2771ccf2ea97cffae1c (cherry picked from commit e51cf3e)
Summary: This will be needed by functorch to have the expected behavior of randomness: Dropout generates a tensor of the right size and then calls `bernoulli_` on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created as `empty_like` but this one just creates `empty` because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls`_dropout_impl` here (not in native_functions.yaml) This shouldn't change the behavior outside of functorch Pull Request resolved: pytorch/pytorch#72078 Reviewed By: zou3519 Differential Revision: D33898338 Pulled By: samdow fbshipit-source-id: 9d9ed59d138d732d9647b2771ccf2ea97cffae1c (cherry picked from commit e51cf3e)
Summary: This will be needed by functorch to have the expected behavior of randomness: Dropout generates a tensor of the right size and then calls `bernoulli_` on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created as `empty_like` but this one just creates `empty` because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls`_dropout_impl` here (not in native_functions.yaml) This shouldn't change the behavior outside of functorch Pull Request resolved: pytorch/pytorch#72078 Reviewed By: zou3519 Differential Revision: D33898338 Pulled By: samdow fbshipit-source-id: 9d9ed59d138d732d9647b2771ccf2ea97cffae1c (cherry picked from commit e51cf3e)
This will be needed by functorch to have the expected behavior of randomness:
Dropout generates a tensor of the right size and then calls
bernoulli_
on that. In order to get the expected behavior from ensembled creation, we'll need to make sure that the generated tensor is a batched tensor.This works mostly because most tensors are created asempty_like
but this one just createsempty
because it needs a new shape, only for feature dropout. There is also no analogous version in CUDA because this directly calls_dropout_impl
here (not in native_functions.yaml)This shouldn't change the behavior outside of functorch