def planChop(self, deltaZ=None, deltaY=None, deltaX=None):

        startPose = self.getPlanningStartPose()

        if deltaZ is None:
            deltaZ = self.chopDistance
        if deltaY is None:
            deltaY = self.chopSidewaysDistance
        if deltaX is None:
            deltaX = 0.0

        linkOffsetFrame = self.ikPlanner.getPalmToHandLink(self.graspingHand)
        handLinkName = self.ikPlanner.getHandLink(self.graspingHand)
        startFrame = self.ikPlanner.getLinkFrameAtPose(handLinkName, startPose)
        endToStartTransform = transformUtils.frameFromPositionAndRPY([deltaZ, -deltaX, -deltaY],
                                                                     [0, 0, 0])
        endFrame = transformUtils.concatenateTransforms([endToStartTransform, startFrame]);
        vis.updateFrame(endFrame, 'debug chop', parent=self.doorHandleAffordance, visible=False, scale=0.2)
        palmToWorld1 = transformUtils.concatenateTransforms([linkOffsetFrame, startFrame])
        palmToWorld2 = transformUtils.concatenateTransforms([linkOffsetFrame, endFrame])

        constraintSet = self.ikPlanner.planEndEffectorGoal(startPose, self.graspingHand, palmToWorld2)
        constraintSet.nominalPoseName = 'q_start'
        constraintSet.ikParameters =  IkParameters(usePointwise=False,
                                                   maxDegreesPerSecond=self.speedLow,
                                                   numberOfAddedKnots=2)

        endPose, info = constraintSet.runIk()


        motionVector = np.array(palmToWorld1.GetPosition()) - np.array(palmToWorld2.GetPosition())
        motionTargetFrame = transformUtils.getTransformFromOriginAndNormal(np.array(palmToWorld2.GetPosition()), motionVector)

        p = self.ikPlanner.createLinePositionConstraint(handLinkName, linkOffsetFrame, motionTargetFrame, lineAxis=2, bounds=[-np.linalg.norm(motionVector), 0.0], positionTolerance=0.001)
        constraintSet.constraints.append(p)

        plan = constraintSet.runIkTraj()
        self.addPlan(plan)
dataset/ETHPy150Open RobotLocomotion/director/src/python/director/doordemo.py/DoorDemo.planChop/swapped operands of `-`