For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).
Python class
PartialsOnly
PartialsOnly
class max.experimental.sharding.PartialsOnly
Bases: object
Cost-model-free picker that only resolves Partial → Replicated.
Picks a feasible action under these rules, applied in order:
- The first action whose input mappings already match the layouts exactly (no reshard).
- The first action whose only per-axis input differences are
Partial → Replicatedtransitions (allreduce-only). - Otherwise: raises
ShardingError.
Never computes a transition cost; never permits S↔R, S(d)↔S(d’),
or R→S reshards on inputs. Useful when you’ve already pinned the
placement of every tensor and just want the picker to allreduce
Partials when an op can’t consume them directly. No on_reshard
diagnostic — this picker raises directly when it can’t satisfy the
P→R-only contract.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!