Shortcuts

torch.Tensor.where

Tensor.where(condition, y) 张量

self.where(condition, y) 等同于 torch.where(condition, self, y)。 参见 torch.where()

优云智算