MCPcopy Create free account
hub / github.com/modelscope/modelscope / __mul__

Method __mul__

modelscope/models/science/unifold/modules/frame.py:238–248  ·  view source on GitHub ↗
(
        self,
        right: torch.Tensor,
    )

Source from the content-addressed store, hash-verified

236 )
237
238 def __mul__(
239 self,
240 right: torch.Tensor,
241 ) -> Frame:
242 if not (isinstance(right, torch.Tensor)):
243 raise TypeError('The other multiplicand must be a Tensor')
244
245 new_rots = self._r * right
246 new_trans = self._t * right[..., None]
247
248 return Frame(new_rots, new_trans)
249
250 def __rmul__(
251 self,

Callers 1

__rmul__Method · 0.95

Calls 1

FrameClass · 0.85

Tested by

no test coverage detected