Skip to content

Commit cda56f1

Browse files
committed
Merge pull request #62 from personalrobotics/Bugfix_GreedyIKPlanner
Fixed GreedyIKPlanner to use active DOFs.
2 parents f3af6bb + 3e701da commit cda56f1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/prpy/planning/workspace.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def PlanWorkspacePath(self, robot, traj, timelimit=5.0,
166166
dt = traj.GetDuration()
167167

168168
# Smallest CSpace step at which to give up
169-
min_step = min(robot.GetDOFResolutions())/100.
169+
min_step = min(robot.GetActiveDOFResolutions())/100.
170170
ik_options = openravepy.IkFilterOptions.CheckEnvCollisions
171171

172172
start_time = time.time()
@@ -192,7 +192,7 @@ def PlanWorkspacePath(self, robot, traj, timelimit=5.0,
192192
step = abs(qnew - qcurr)
193193
if (max(step) < min_step) and qtraj:
194194
raise PlanningError('Not making progress.')
195-
infeasible_step = any(step > robot.GetDOFResolutions())
195+
infeasible_step = any(step > robot.GetActiveDOFResolutions())
196196
if infeasible_step:
197197
# Backtrack and try half the step
198198
dt = dt/2.0

0 commit comments

Comments
 (0)