Skip to main content

raygeo.ops.assembly

Motion-path assembly: turning raw geometry primitives into Ops.

Functions in this module compose geo-layer primitives (polylines, arcs, polygons) into complete motion sequences represented as Ops objects. They decide traversal order, linking strategy, lead-in/out, overscan, and tab insertion — concerns that belong to motion assembly rather than pure geometry.

AssemblyResult

Universal return type for every assembly-level generator.

Returned by assemblers such as generate_helix, generate_toroidal_clear, generate_slot, and all other assembly-level motion functions. Contains the generated Ops sequence, the set of polygons that this operation clears, and the tool pose at the start and end of the path.

end

end: search.ToolPose

ops

ops: ops.Ops

start

start: search.ToolPose

trace

trace: Optional[Any]

from_ops()

from_ops(
ops: ops.Ops,
start: tuple[float, float, float],
end: tuple[float, float, float],
) -> AssemblyResult

Construct an AssemblyResult from ops, start, and end poses.

ParameterTypeDescription
opsops.Ops
starttuple[float, float, float]
endtuple[float, float, float]
ReturnsAssemblyResult

write_trace()

write_trace(path: str, source: str, label: str) -> None

Write this result's trace events to a trace file.

Emits a root "workplan" span with one child assembler span containing either the self-traced events or a minimal init/exit pair.

ParameterTypeDescription
pathstr
sourcestr
labelstr
ReturnsNone