tesseract_robotics.time_parameterization¶
Time parameterization: the algorithms (time-optimal trajectory generation, iterative spline parameterization, constant TCP speed, Ruckig smoothing) and the profiles that configure them in the TimeParameterization task composer nodes. InstructionsTrajectory is the view of a CompositeInstruction the algorithms consume; it raises StaleTrajectoryError when the program changed under it. The Task Composer User Guide covers the pipelines that run them.
Reference¶
tesseract_time_parameterization Python bindings
StaleTrajectoryError
¶
Bases: RuntimeError
The program changed after the InstructionsTrajectory was built; build a new one.
InstructionsTrajectory
¶
__init__
¶
Build a trajectory view over the move instructions of program.
The trajectory keeps program alive and reads and writes its waypoints in place
(setData changes program). Once instructions are appended, inserted or erased
in program, every method raises StaleTrajectoryError: build a new
trajectory. Each call re-flattens program, O(number of instructions).
Raises:
| Type | Description |
|---|---|
StaleTrajectoryError
|
on any method call after |
IndexError
|
an index method got |
getPosition
¶
Joint positions of waypoint i.
getVelocity
¶
Joint velocities of waypoint i.
getAcceleration
¶
Joint accelerations of waypoint i.
setData
¶
setData(i: int, velocity: Annotated[NDArray[float64], dict(shape=(None,), order=C)] | Sequence[float], acceleration: Annotated[NDArray[float64], dict(shape=(None,), order=C)] | Sequence[float], time: float) -> None
Write velocity, acceleration and time from start [s] into waypoint i.
isTimeStrictlyIncreasing
¶
True if every waypoint's time is above the previous one's.
TimeOptimalTrajectoryGenerationCompositeProfile
¶
Bases: Profile
override_limits
property
writable
¶
Use velocity_limits / acceleration_limits (/ jerk_limits) instead of the joint group's.
velocity_limits
property
writable
¶
Per-joint (lower, upper) velocity limits [m/s or rad/s], used when override_limits.
acceleration_limits
property
writable
¶
Per-joint (lower, upper) acceleration limits [m/s² or rad/s²], used when override_limits.
max_velocity_scaling_factor
property
writable
¶
Fraction of the velocity limits to plan with, in (0, 1].
max_acceleration_scaling_factor
property
writable
¶
Fraction of the acceleration limits to plan with, in (0, 1].
path_tolerance
property
writable
¶
How far the path may deviate from the waypoints where TOTG blends them [rad or m, joint space].
min_angle_change
property
writable
¶
Smallest direction change [rad] TOTG treats as a corner to blend.
createKey
staticmethod
¶
The key every profile of this class carries in a ProfileDictionary.
IterativeSplineParameterizationCompositeProfile
¶
Bases: Profile
add_points
property
writable
¶
Add points between the first two and the last two waypoints for smoother start and end.
override_limits
property
writable
¶
Use velocity_limits / acceleration_limits (/ jerk_limits) instead of the joint group's.
velocity_limits
property
writable
¶
Per-joint (lower, upper) velocity limits [m/s or rad/s], used when override_limits.
acceleration_limits
property
writable
¶
Per-joint (lower, upper) acceleration limits [m/s² or rad/s²], used when override_limits.
max_velocity_scaling_factor
property
writable
¶
Fraction of the velocity limits to plan with, in (0, 1].
max_acceleration_scaling_factor
property
writable
¶
Fraction of the acceleration limits to plan with, in (0, 1].
minimum_time_delta
property
writable
¶
Smallest time step between waypoints [s].
createKey
staticmethod
¶
The key every profile of this class carries in a ProfileDictionary.
IterativeSplineParameterizationMoveProfile
¶
Bases: Profile
max_velocity_scaling_factor
property
writable
¶
Fraction of the velocity limits to plan with, in (0, 1].
max_acceleration_scaling_factor
property
writable
¶
Fraction of the acceleration limits to plan with, in (0, 1].
createKey
staticmethod
¶
The key every profile of this class carries in a ProfileDictionary.
TimeParameterization
¶
TimeOptimalTrajectoryGeneration
¶
Bases: TimeParameterization
IterativeSplineParameterization
¶
Bases: TimeParameterization
ConstantTCPSpeedParameterizationCompositeProfile
¶
Bases: Profile
max_translational_velocity
property
writable
¶
TCP speed limit [m/s].
max_rotational_velocity
property
writable
¶
TCP angular speed limit [rad/s].
max_translational_acceleration
property
writable
¶
TCP acceleration limit [m/s²].
max_rotational_acceleration
property
writable
¶
TCP angular acceleration limit [rad/s²].
max_velocity_scaling_factor
property
writable
¶
Fraction of the velocity limits to plan with, in (0, 1].
max_acceleration_scaling_factor
property
writable
¶
Fraction of the acceleration limits to plan with, in (0, 1].
createKey
staticmethod
¶
The key every profile of this class carries in a ProfileDictionary.
ConstantTCPSpeedParameterization
¶
Bases: TimeParameterization
RuckigTrajectorySmoothingCompositeProfile
¶
Bases: Profile
duration_extension_fraction
property
writable
¶
Fraction by which each retry stretches the segment durations.
max_duration_extension_factor
property
writable
¶
Largest total stretch before smoothing gives up.
override_limits
property
writable
¶
Use velocity_limits / acceleration_limits (/ jerk_limits) instead of the joint group's.
velocity_limits
property
writable
¶
Per-joint (lower, upper) velocity limits [m/s or rad/s], used when override_limits.
acceleration_limits
property
writable
¶
Per-joint (lower, upper) acceleration limits [m/s² or rad/s²], used when override_limits.
jerk_limits
property
writable
¶
Per-joint (lower, upper) jerk limits [m/s³ or rad/s³], used when override_limits.
createKey
staticmethod
¶
The key every profile of this class carries in a ProfileDictionary.
RuckigTrajectorySmoothing
¶
Bases: TimeParameterization
ScalingsLengthError
¶
Bases: ValueError
rescaleTimings got a scalings list that is not len(program) long.
rescaleTimings
¶
Rescale the timing of each sub-composite of program in place.
Every element of program must be a CompositeInstruction; scalings[i] scales
element i linearly (0.5 is half speed). A scaling below 1e-6 is replaced by 1.0
with only a logged warning.
Raises:
| Type | Description |
|---|---|
ScalingsLengthError
|
|