<s> import sys , rospy , tf , actionlib , moveit_commander <EOL> from geometry_msgs . msg import * <EOL> from move_base_msgs . msg import MoveBaseAction , MoveBaseGoal <EOL> from tf . transformations import quaternion_from_euler <EOL> from control_msgs . msg import ( GripperCommandAction , GripperCommandGoal ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> moveit_commander . roscpp_initialize ( sys . argv ) <EOL> rospy . init_node ( '<STR_LIT>' ) <EOL> args = rospy . myargv ( argv = sys . argv ) <EOL> gripper = actionlib . SimpleActionClient ( "<STR_LIT>" , <EOL> GripperCommandAction ) <EOL> gripper . wait_for_server ( ) <EOL> move_base = actionlib . SimpleActionClient ( '<STR_LIT>' , MoveBaseAction ) <EOL> move_base . wait_for_server ( ) <EOL> goal = MoveBaseGoal ( ) <EOL> goal . target_pose . header . frame_id = '<STR_LIT>' <EOL> goal . target_pose . pose . position . x = <NUM_LIT:4> <EOL> orient = Quaternion ( * quaternion_from_euler ( <NUM_LIT:0> , <NUM_LIT:0> , <NUM_LIT:0> ) ) <EOL> goal . target_pose . pose . orientation = orient <EOL> move_base . send_goal ( goal ) <EOL> move_base . wait_for_result ( ) <EOL> arm = moveit_commander . MoveGroupCommander ( "<STR_LIT>" ) <EOL> arm . allow_replanning ( True ) <EOL> p = Pose ( ) <EOL> p . position . x = <NUM_LIT> <EOL> p . position . z = <NUM_LIT> <EOL> p . orientation = Quaternion ( * quaternion_from_euler ( <NUM_LIT:0> , <NUM_LIT:0.5> , <NUM_LIT:0> ) ) <EOL> arm . set_pose_target ( p ) <EOL> arm . go ( True ) <EOL> gripper_goal = GripperCommandGoal ( ) <EOL> gripper_goal . command . max_effort = <NUM_LIT> <EOL> gripper_goal . command . position = <NUM_LIT> <EOL> gripper . send_goal ( gripper_goal ) <EOL> gripper . wait_for_result ( rospy . Duration ( <NUM_LIT:1.0> ) ) <EOL> p . position . x = <NUM_LIT> <EOL> p . position . y = - <NUM_LIT> <EOL> p . position . z = <NUM_LIT> <EOL> p . orientation = Quaternion ( * quaternion_from_euler ( <NUM_LIT:0> , - <NUM_LIT> , - <NUM_LIT> ) ) <EOL> arm . set_pose_target ( p ) <EOL> arm . go ( True ) <EOL> goal . target_pose . pose . position . x = <NUM_LIT:0> <EOL> move_base . send_goal ( goal ) <EOL> move_base . wait_for_result ( ) </s>
