torch.Tensor.pin_memory¶ Tensor.pin_memory() → Tensor¶ 将 tensor 复制到锁页内存(如果尚未锁定)。默认情况下,锁页内存所在的设备将是当前的加速器。