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

Class FTMapBasic

exir/tests/control_flow_models.py:77–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

75
76
77class FTMapBasic(Module):
78 def __init__(self):
79 super().__init__()
80
81 def forward(self, xs, y):
82 def f(x, y):
83 return x + y
84
85 return torch_map(f, xs, y) + xs
86
87 def get_random_inputs(self):
88 return torch.rand(2, 4), torch.rand(4)
89
90
91class FTMapDynShape(Module):

Callers 2

test_alloc_node_specMethod · 0.90
test_ft_map_basicMethod · 0.90

Calls

no outgoing calls

Tested by 2

test_alloc_node_specMethod · 0.72
test_ft_map_basicMethod · 0.72