MCPcopy Create free account
hub / github.com/microsoft/TRELLIS / forward

Method forward

trellis/modules/sparse/nonlinearity.py:14–15  ·  view source on GitHub ↗
(self, input: SparseTensor)

Source from the content-addressed store, hash-verified

12
13class SparseReLU(nn.ReLU):
14 def forward(self, input: SparseTensor) -> SparseTensor:
15 return input.replace(super().forward(input.feats))
16
17
18class SparseSiLU(nn.SiLU):

Callers 2

forwardMethod · 0.45
forwardMethod · 0.45

Calls 1

replaceMethod · 0.80

Tested by

no test coverage detected