Rename Tensor._storage to Tensor.untyped_storage and update docs (#91414)

Fixes #89224

Pull Request resolved: https://github.com/pytorch/pytorch/pull/91414
Approved by: https://github.com/ezyang
This commit is contained in:
Kurt Mohler
2022-12-28 19:21:34 +00:00
committed by PyTorch MergeBot
parent 5b223c43ec
commit 08a47549af
14 changed files with 45 additions and 29 deletions

View File

@ -102,7 +102,7 @@ class TestViewOps(TestCase):
# Note: only validates storage on native device types
# because some accelerators, like XLA, do not expose storage
if base.device.type == 'cpu' or base.device.type == 'cuda':
if base._storage().data_ptr() != other._storage().data_ptr():
if base.untyped_storage().data_ptr() != other.untyped_storage().data_ptr():
return False
return True