MCPcopy Index your code
hub / github.com/microsoft/TRELLIS / __sub__

Method __sub__

trellis/modules/sparse/basic.py:326–327  ·  view source on GitHub ↗
(self, other: Union[torch.Tensor, 'SparseTensor', float])

Source from the content-addressed store, hash-verified

324 return self.__elemwise__(other, torch.add)
325
326 def __sub__(self, other: Union[torch.Tensor, 'SparseTensor', float]) -> 'SparseTensor':
327 return self.__elemwise__(other, torch.sub)
328
329 def __rsub__(self, other: Union[torch.Tensor, 'SparseTensor', float]) -> 'SparseTensor':
330 return self.__elemwise__(other, lambda x, y: torch.sub(y, x))

Callers

nothing calls this directly

Calls 1

__elemwise__Method · 0.95

Tested by

no test coverage detected