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。
torch.Tensor.long¶self.long() 等價於 self.to(torch.int64)。請參閱 to()。
memory_format (torch.memory_format, 可選) – 返回張量所需的記憶體格式。預設值: torch.preserve_format。