For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).
Python function
mode
mode()
max.experimental.sharding.mode(solver)
Binds solver for the duration of a with block or function call.
Usable both as a context manager with mode(S): and as a
decorator @mode(S) – contextlib.contextmanager() returns
a ContextDecorator that supports both. solver must be
a Solver instance (one of GreedyReshard,
NoReshard, PartialsOnly, or any callable matching
the Solver protocol).