parameters: (self, group, target, width)
return_statement: return True
docstring: Pick up a target using the planning group
docstring_summary: Pick up a target using the planning group
docstring_tokens: Pick up a target using the planning group
function: def _pickup(self, group, target, width):
          """
          Pick up a target using the planning group
          """
  
          # Obtain possible grasps from the grasp generator server:
          grasps = self._generate_grasps(self._pose_coke_can, width)
  
          # Create and send Pickup goal:
          goal = self._create_pickup_goal(group, target, grasps)
  
          state = self._pickup_ac.send_goal_and_wait(goal)
          if state != GoalStatus.SUCCEEDED:
              rospy.logerr('Pick up goal failed!: %s' % self._pickup_ac.get_goal_status_text())
              return None
  
          result = self._pickup_ac.get_result()
  
          # Check for error:
          err = result.error_code.val
          if err != MoveItErrorCodes.SUCCESS:
              rospy.logwarn('Group %s cannot pick up target %s!: %s' % (group, target, str(moveit_error_dict[err])))
  
              return False
  
          return True
function_tokens: def _pickup ( self , group , target , width ) : # Obtain possible grasps from the grasp generator server: grasps = self . _generate_grasps ( self . _pose_coke_can , width ) # Create and send Pickup goal: goal = self . _create_pickup_goal ( group , target , grasps ) state = self . _pickup_ac . send_goal_and_wait ( goal ) if state != GoalStatus . SUCCEEDED : rospy . logerr ( 'Pick up goal failed!: %s' % self . _pickup_ac . get_goal_status_text ( ) ) return None result = self . _pickup_ac . get_result ( ) # Check for error: err = result . error_code . val if err != MoveItErrorCodes . SUCCESS : rospy . logwarn ( 'Group %s cannot pick up target %s!: %s' % ( group , target , str ( moveit_error_dict [ err ] ) ) ) return False return True