torch.Tensor.coalesce¶ Tensor.coalesce() → Tensor 如果 self 是一个未合并的张量,则返回 self 的合并副本。 返回 self ,如果 self 是一个合并的张量。 警告 如果 self 不是一个稀疏的 COO 张量,将抛出错误。