Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documenting why setFromIK in computeCartesianPath does not use random restarts #1076

Merged
merged 2 commits into from
Oct 10, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions moveit_core/robot_state/src/robot_state.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1927,6 +1927,8 @@ double RobotState::computeCartesianPath(const JointModelGroup* group, std::vecto
Eigen::Affine3d pose(start_quaternion.slerp(percentage, target_quaternion));
pose.translation() = percentage * rotated_target.translation() + (1 - percentage) * start_pose.translation();

// Explicitly use a single IK attempt only: We want a smooth trajectory.
// Random seeding (of additional attempts) would probably create IK jumps.
if (setFromIK(group, pose, link->getName(), 1, 0.0, validCallback, options))
traj.push_back(RobotStatePtr(new RobotState(*this)));
else
Expand Down