Shortcuts

torch.Tensor.is_shared

Tensor.is_shared()[源代码]

检查张量是否在共享内存中。

对于CUDA张量,这总是True