pyboxbuilder.packing.guillotine.pack_guillotine

pyboxbuilder.packing.guillotine.pack_guillotine(container: tuple[float, float, float], items: list[Item], *, node_budget: int = 200000, obstacles: Sequence[tuple[float, float, float, float, float, float]] = ()) → list[Placed] | None[source]

Pack items into container around optional obstacles, or return None.

Parameters:
container: tuple[float, float, float]

(width, length, height) of the space to fill in mm.

items: list[Item]

Boxes to place (may carry size_options or stack_members).

node_budget: int = 200000

Search nodes before giving up.

obstacles: Sequence[tuple[float, float, float, float, float, float]] = ()

Already-placed (x, y, z, w, l, h) boxes to pack around.

Returns:

List of Placed records, or None if no packing was found within budget.