torch.Tensor.long¶
- Tensor.long(memory_format=torch.preserve_format) Tensor¶
self.long()等效于self.to(torch.int64)。见to().- 参数
memory_format (
torch.memory_format, 可选) – 返回的张量的所需内存格式。默认值:torch.preserve_format。
self.long() 等效于 self.to(torch.int64)。见 to().
memory_format (torch.memory_format, 可选) – 返回的张量的所需内存格式。默认值:torch.preserve_format。