Closed
Conversation
Summary: Pull Request resolved: pytorch#10138 Note that `TensorCPU` and `TensorGPU` are all refined to be `Tensor` now. Basically they are the same thing. So check like `blob.IsType<TensorCPU>()` is no longer safe as `TensorGPU` can pass the check too. We need to systematically weed out the such usage in our codebase... @[100008320710723:jerryzh] Differential Revision: D9115273 fbshipit-source-id: ea5ee8f5655fc9e600750d0f029857858b2cda9c
1dcd684 to
4b5d078
Compare
goodlux
pushed a commit
to goodlux/pytorch
that referenced
this pull request
Aug 15, 2018
Summary: Pull Request resolved: pytorch#10138 Note that `TensorCPU` and `TensorGPU` are all refined to be `Tensor` now. Basically they are the same thing. So check like `blob.IsType<TensorCPU>()` is no longer safe as `TensorGPU` can pass the check too. We need to systematically weed out the such usage in our codebase... @[100008320710723:jerryzh] Reviewed By: houseroad Differential Revision: D9115273 fbshipit-source-id: 13b293c73691002eac34e095cdcd96c27183e875
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Note that
TensorCPUandTensorGPUare all refined to beTensornow. Basically they are the same thing. So check likeblob.IsType<TensorCPU>()is no longer safe asTensorGPUcan pass the check too.We need to systematically weed out the such usage in our codebase...
Differential Revision: D9115273