MCPcopy Create free account
hub / github.com/apple/axlearn / __call__

Method __call__

axlearn/common/debug_utils.py:49–55  ·  view source on GitHub ↗

Lowers, compiles, and runs the function with provided arguments and keyword arguments.

(
        self, *args, compiler_options: Optional[dict[str, Union[str, bool]]] = None, **kwargs
    )

Source from the content-addressed store, hash-verified

47 self._checkified_jit_handle = checkified_jit_handle
48
49 def __call__(
50 self, *args, compiler_options: Optional[dict[str, Union[str, bool]]] = None, **kwargs
51 ) -> Any:
52 """Lowers, compiles, and runs the function with provided arguments and keyword arguments."""
53 lowered = self.lower(*args, **kwargs)
54 compiled = lowered.compile(compiler_options)
55 return compiled(*args, **kwargs)
56
57 def lower(self, *args, **kwargs) -> _CheckifyLoweredFnWrapper:
58 """Traces and lowers the function using the provided arguments."""

Callers

nothing calls this directly

Calls 2

lowerMethod · 0.95
compileMethod · 0.80

Tested by

no test coverage detected