MCPcopy Create free account
hub / github.com/pytorch/executorch / forward

Method forward

test/models/export_delegated_program.py:55–60  ·  view source on GitHub ↗
(
        self, a: torch.Tensor, x: torch.Tensor, b: torch.Tensor
    )

Source from the content-addressed store, hash-verified

53 super().__init__()
54
55 def forward(
56 self, a: torch.Tensor, x: torch.Tensor, b: torch.Tensor
57 ) -> torch.Tensor:
58 y: torch.Tensor = torch.mm(a, x)
59 z: torch.Tensor = torch.add(y, b)
60 return z
61
62 def get_random_inputs(self) -> Sequence[torch.Tensor]:
63 return (torch.ones(2, 2), 2 * torch.ones(2, 2), 3 * torch.ones(2, 2))

Callers

nothing calls this directly

Calls 1

addMethod · 0.45

Tested by

no test coverage detected