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

Function wrapper

exir/control_flow.py:190–199  ·  view source on GitHub ↗
(
            *args: torch.Tensor, **kwargs: Tuple[torch.Tensor]
        )

Source from the content-addressed store, hash-verified

188 f: Callable[..., Tuple[torch.Tensor]]
189 ) -> Callable[..., Union[torch.Tensor, Tuple[torch.Tensor]]]:
190 def wrapper(
191 *args: torch.Tensor, **kwargs: Tuple[torch.Tensor]
192 ) -> Tuple[torch.Tensor]:
193 if kwargs:
194 raise ExportError(
195 ExportErrorType.NOT_SUPPORTED,
196 "kwargs are not supported for @tracing_context decorated functions.",
197 )
198
199 return f(*args)
200
201 wrapper.__tracing_inputs__ = inputs # pyre-ignore
202 return wrapper

Callers 1

single_returnFunction · 0.70

Calls 1

ExportErrorClass · 0.90

Tested by

no test coverage detected