00001 """autogenerated by genpy from pr2_object_manipulation_msgs/IMGUIAction.msg. Do not edit."""
00002 import sys
00003 python3 = True if sys.hexversion > 0x03000000 else False
00004 import genpy
00005 import struct
00006
00007 import pr2_object_manipulation_msgs.msg
00008 import object_manipulation_msgs.msg
00009 import actionlib_msgs.msg
00010 import geometry_msgs.msg
00011 import sensor_msgs.msg
00012 import std_msgs.msg
00013 import genpy
00014 import household_objects_database_msgs.msg
00015
00016 class IMGUIAction(genpy.Message):
00017 _md5sum = "61c52671c98ebe2204744df83f0f9c32"
00018 _type = "pr2_object_manipulation_msgs/IMGUIAction"
00019 _has_header = False
00020 _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00021
00022 IMGUIActionGoal action_goal
00023 IMGUIActionResult action_result
00024 IMGUIActionFeedback action_feedback
00025
00026 ================================================================================
00027 MSG: pr2_object_manipulation_msgs/IMGUIActionGoal
00028 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00029
00030 Header header
00031 actionlib_msgs/GoalID goal_id
00032 IMGUIGoal goal
00033
00034 ================================================================================
00035 MSG: std_msgs/Header
00036 # Standard metadata for higher-level stamped data types.
00037 # This is generally used to communicate timestamped data
00038 # in a particular coordinate frame.
00039 #
00040 # sequence ID: consecutively increasing ID
00041 uint32 seq
00042 #Two-integer timestamp that is expressed as:
00043 # * stamp.secs: seconds (stamp_secs) since epoch
00044 # * stamp.nsecs: nanoseconds since stamp_secs
00045 # time-handling sugar is provided by the client library
00046 time stamp
00047 #Frame this data is associated with
00048 # 0: no frame
00049 # 1: global frame
00050 string frame_id
00051
00052 ================================================================================
00053 MSG: actionlib_msgs/GoalID
00054 # The stamp should store the time at which this goal was requested.
00055 # It is used by an action server when it tries to preempt all
00056 # goals that were requested before a certain time
00057 time stamp
00058
00059 # The id provides a way to associate feedback and
00060 # result message with specific goal requests. The id
00061 # specified must be unique.
00062 string id
00063
00064
00065 ================================================================================
00066 MSG: pr2_object_manipulation_msgs/IMGUIGoal
00067 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00068
00069 IMGUIOptions options
00070 IMGUICommand command
00071
00072
00073 ================================================================================
00074 MSG: pr2_object_manipulation_msgs/IMGUIOptions
00075
00076 # collision checking enabled
00077 bool collision_checked
00078
00079 # 0=call gripper click
00080 # 1=grasp the provided graspable object
00081 int32 grasp_selection
00082
00083 # 0=right, 1=left arm
00084 int32 arm_selection
00085
00086 # for RESET commands
00087 # 0=reset collision objects
00088 # 1=reset attached objects
00089 int32 reset_choice
00090
00091 # for MOVE_ARM commands
00092 # 0=side
00093 # 1=front
00094 # 2=side handoff
00095 int32 arm_action_choice
00096
00097 # for MOVE_ARM commands
00098 # 0=open-loop
00099 # 1=with planner
00100 int32 arm_planner_choice
00101
00102 # for MOVE_GRIPPER commands
00103 # opening of gripper (0=closed..100=open)
00104 int32 gripper_slider_position
00105
00106 # used if grasp_selection == 1
00107 object_manipulation_msgs/GraspableObject selected_object
00108
00109 # indicates obstacles that can be moved during grasping
00110 # presumably, the operator has marked these in some fashion
00111 object_manipulation_msgs/GraspableObject[] movable_obstacles
00112
00113 # more options..
00114 IMGUIAdvancedOptions adv_options
00115
00116 ================================================================================
00117 MSG: object_manipulation_msgs/GraspableObject
00118 # an object that the object_manipulator can work on
00119
00120 # a graspable object can be represented in multiple ways. This message
00121 # can contain all of them. Which one is actually used is up to the receiver
00122 # of this message. When adding new representations, one must be careful that
00123 # they have reasonable lightweight defaults indicating that that particular
00124 # representation is not available.
00125
00126 # the tf frame to be used as a reference frame when combining information from
00127 # the different representations below
00128 string reference_frame_id
00129
00130 # potential recognition results from a database of models
00131 # all poses are relative to the object reference pose
00132 household_objects_database_msgs/DatabaseModelPose[] potential_models
00133
00134 # the point cloud itself
00135 sensor_msgs/PointCloud cluster
00136
00137 # a region of a PointCloud2 of interest
00138 object_manipulation_msgs/SceneRegion region
00139
00140 # the name that this object has in the collision environment
00141 string collision_name
00142 ================================================================================
00143 MSG: household_objects_database_msgs/DatabaseModelPose
00144 # Informs that a specific model from the Model Database has been
00145 # identified at a certain location
00146
00147 # the database id of the model
00148 int32 model_id
00149
00150 # the pose that it can be found in
00151 geometry_msgs/PoseStamped pose
00152
00153 # a measure of the confidence level in this detection result
00154 float32 confidence
00155
00156 # the name of the object detector that generated this detection result
00157 string detector_name
00158
00159 ================================================================================
00160 MSG: geometry_msgs/PoseStamped
00161 # A Pose with reference coordinate frame and timestamp
00162 Header header
00163 Pose pose
00164
00165 ================================================================================
00166 MSG: geometry_msgs/Pose
00167 # A representation of pose in free space, composed of postion and orientation.
00168 Point position
00169 Quaternion orientation
00170
00171 ================================================================================
00172 MSG: geometry_msgs/Point
00173 # This contains the position of a point in free space
00174 float64 x
00175 float64 y
00176 float64 z
00177
00178 ================================================================================
00179 MSG: geometry_msgs/Quaternion
00180 # This represents an orientation in free space in quaternion form.
00181
00182 float64 x
00183 float64 y
00184 float64 z
00185 float64 w
00186
00187 ================================================================================
00188 MSG: sensor_msgs/PointCloud
00189 # This message holds a collection of 3d points, plus optional additional
00190 # information about each point.
00191
00192 # Time of sensor data acquisition, coordinate frame ID.
00193 Header header
00194
00195 # Array of 3d points. Each Point32 should be interpreted as a 3d point
00196 # in the frame given in the header.
00197 geometry_msgs/Point32[] points
00198
00199 # Each channel should have the same number of elements as points array,
00200 # and the data in each channel should correspond 1:1 with each point.
00201 # Channel names in common practice are listed in ChannelFloat32.msg.
00202 ChannelFloat32[] channels
00203
00204 ================================================================================
00205 MSG: geometry_msgs/Point32
00206 # This contains the position of a point in free space(with 32 bits of precision).
00207 # It is recommeded to use Point wherever possible instead of Point32.
00208 #
00209 # This recommendation is to promote interoperability.
00210 #
00211 # This message is designed to take up less space when sending
00212 # lots of points at once, as in the case of a PointCloud.
00213
00214 float32 x
00215 float32 y
00216 float32 z
00217 ================================================================================
00218 MSG: sensor_msgs/ChannelFloat32
00219 # This message is used by the PointCloud message to hold optional data
00220 # associated with each point in the cloud. The length of the values
00221 # array should be the same as the length of the points array in the
00222 # PointCloud, and each value should be associated with the corresponding
00223 # point.
00224
00225 # Channel names in existing practice include:
00226 # "u", "v" - row and column (respectively) in the left stereo image.
00227 # This is opposite to usual conventions but remains for
00228 # historical reasons. The newer PointCloud2 message has no
00229 # such problem.
00230 # "rgb" - For point clouds produced by color stereo cameras. uint8
00231 # (R,G,B) values packed into the least significant 24 bits,
00232 # in order.
00233 # "intensity" - laser or pixel intensity.
00234 # "distance"
00235
00236 # The channel name should give semantics of the channel (e.g.
00237 # "intensity" instead of "value").
00238 string name
00239
00240 # The values array should be 1-1 with the elements of the associated
00241 # PointCloud.
00242 float32[] values
00243
00244 ================================================================================
00245 MSG: object_manipulation_msgs/SceneRegion
00246 # Point cloud
00247 sensor_msgs/PointCloud2 cloud
00248
00249 # Indices for the region of interest
00250 int32[] mask
00251
00252 # One of the corresponding 2D images, if applicable
00253 sensor_msgs/Image image
00254
00255 # The disparity image, if applicable
00256 sensor_msgs/Image disparity_image
00257
00258 # Camera info for the camera that took the image
00259 sensor_msgs/CameraInfo cam_info
00260
00261 # a 3D region of interest for grasp planning
00262 geometry_msgs/PoseStamped roi_box_pose
00263 geometry_msgs/Vector3 roi_box_dims
00264
00265 ================================================================================
00266 MSG: sensor_msgs/PointCloud2
00267 # This message holds a collection of N-dimensional points, which may
00268 # contain additional information such as normals, intensity, etc. The
00269 # point data is stored as a binary blob, its layout described by the
00270 # contents of the "fields" array.
00271
00272 # The point cloud data may be organized 2d (image-like) or 1d
00273 # (unordered). Point clouds organized as 2d images may be produced by
00274 # camera depth sensors such as stereo or time-of-flight.
00275
00276 # Time of sensor data acquisition, and the coordinate frame ID (for 3d
00277 # points).
00278 Header header
00279
00280 # 2D structure of the point cloud. If the cloud is unordered, height is
00281 # 1 and width is the length of the point cloud.
00282 uint32 height
00283 uint32 width
00284
00285 # Describes the channels and their layout in the binary data blob.
00286 PointField[] fields
00287
00288 bool is_bigendian # Is this data bigendian?
00289 uint32 point_step # Length of a point in bytes
00290 uint32 row_step # Length of a row in bytes
00291 uint8[] data # Actual point data, size is (row_step*height)
00292
00293 bool is_dense # True if there are no invalid points
00294
00295 ================================================================================
00296 MSG: sensor_msgs/PointField
00297 # This message holds the description of one point entry in the
00298 # PointCloud2 message format.
00299 uint8 INT8 = 1
00300 uint8 UINT8 = 2
00301 uint8 INT16 = 3
00302 uint8 UINT16 = 4
00303 uint8 INT32 = 5
00304 uint8 UINT32 = 6
00305 uint8 FLOAT32 = 7
00306 uint8 FLOAT64 = 8
00307
00308 string name # Name of field
00309 uint32 offset # Offset from start of point struct
00310 uint8 datatype # Datatype enumeration, see above
00311 uint32 count # How many elements in the field
00312
00313 ================================================================================
00314 MSG: sensor_msgs/Image
00315 # This message contains an uncompressed image
00316 # (0, 0) is at top-left corner of image
00317 #
00318
00319 Header header # Header timestamp should be acquisition time of image
00320 # Header frame_id should be optical frame of camera
00321 # origin of frame should be optical center of cameara
00322 # +x should point to the right in the image
00323 # +y should point down in the image
00324 # +z should point into to plane of the image
00325 # If the frame_id here and the frame_id of the CameraInfo
00326 # message associated with the image conflict
00327 # the behavior is undefined
00328
00329 uint32 height # image height, that is, number of rows
00330 uint32 width # image width, that is, number of columns
00331
00332 # The legal values for encoding are in file src/image_encodings.cpp
00333 # If you want to standardize a new string format, join
00334 # ros-users@lists.sourceforge.net and send an email proposing a new encoding.
00335
00336 string encoding # Encoding of pixels -- channel meaning, ordering, size
00337 # taken from the list of strings in src/image_encodings.cpp
00338
00339 uint8 is_bigendian # is this data bigendian?
00340 uint32 step # Full row length in bytes
00341 uint8[] data # actual matrix data, size is (step * rows)
00342
00343 ================================================================================
00344 MSG: sensor_msgs/CameraInfo
00345 # This message defines meta information for a camera. It should be in a
00346 # camera namespace on topic "camera_info" and accompanied by up to five
00347 # image topics named:
00348 #
00349 # image_raw - raw data from the camera driver, possibly Bayer encoded
00350 # image - monochrome, distorted
00351 # image_color - color, distorted
00352 # image_rect - monochrome, rectified
00353 # image_rect_color - color, rectified
00354 #
00355 # The image_pipeline contains packages (image_proc, stereo_image_proc)
00356 # for producing the four processed image topics from image_raw and
00357 # camera_info. The meaning of the camera parameters are described in
00358 # detail at http://www.ros.org/wiki/image_pipeline/CameraInfo.
00359 #
00360 # The image_geometry package provides a user-friendly interface to
00361 # common operations using this meta information. If you want to, e.g.,
00362 # project a 3d point into image coordinates, we strongly recommend
00363 # using image_geometry.
00364 #
00365 # If the camera is uncalibrated, the matrices D, K, R, P should be left
00366 # zeroed out. In particular, clients may assume that K[0] == 0.0
00367 # indicates an uncalibrated camera.
00368
00369 #######################################################################
00370 # Image acquisition info #
00371 #######################################################################
00372
00373 # Time of image acquisition, camera coordinate frame ID
00374 Header header # Header timestamp should be acquisition time of image
00375 # Header frame_id should be optical frame of camera
00376 # origin of frame should be optical center of camera
00377 # +x should point to the right in the image
00378 # +y should point down in the image
00379 # +z should point into the plane of the image
00380
00381
00382 #######################################################################
00383 # Calibration Parameters #
00384 #######################################################################
00385 # These are fixed during camera calibration. Their values will be the #
00386 # same in all messages until the camera is recalibrated. Note that #
00387 # self-calibrating systems may "recalibrate" frequently. #
00388 # #
00389 # The internal parameters can be used to warp a raw (distorted) image #
00390 # to: #
00391 # 1. An undistorted image (requires D and K) #
00392 # 2. A rectified image (requires D, K, R) #
00393 # The projection matrix P projects 3D points into the rectified image.#
00394 #######################################################################
00395
00396 # The image dimensions with which the camera was calibrated. Normally
00397 # this will be the full camera resolution in pixels.
00398 uint32 height
00399 uint32 width
00400
00401 # The distortion model used. Supported models are listed in
00402 # sensor_msgs/distortion_models.h. For most cameras, "plumb_bob" - a
00403 # simple model of radial and tangential distortion - is sufficent.
00404 string distortion_model
00405
00406 # The distortion parameters, size depending on the distortion model.
00407 # For "plumb_bob", the 5 parameters are: (k1, k2, t1, t2, k3).
00408 float64[] D
00409
00410 # Intrinsic camera matrix for the raw (distorted) images.
00411 # [fx 0 cx]
00412 # K = [ 0 fy cy]
00413 # [ 0 0 1]
00414 # Projects 3D points in the camera coordinate frame to 2D pixel
00415 # coordinates using the focal lengths (fx, fy) and principal point
00416 # (cx, cy).
00417 float64[9] K # 3x3 row-major matrix
00418
00419 # Rectification matrix (stereo cameras only)
00420 # A rotation matrix aligning the camera coordinate system to the ideal
00421 # stereo image plane so that epipolar lines in both stereo images are
00422 # parallel.
00423 float64[9] R # 3x3 row-major matrix
00424
00425 # Projection/camera matrix
00426 # [fx' 0 cx' Tx]
00427 # P = [ 0 fy' cy' Ty]
00428 # [ 0 0 1 0]
00429 # By convention, this matrix specifies the intrinsic (camera) matrix
00430 # of the processed (rectified) image. That is, the left 3x3 portion
00431 # is the normal camera intrinsic matrix for the rectified image.
00432 # It projects 3D points in the camera coordinate frame to 2D pixel
00433 # coordinates using the focal lengths (fx', fy') and principal point
00434 # (cx', cy') - these may differ from the values in K.
00435 # For monocular cameras, Tx = Ty = 0. Normally, monocular cameras will
00436 # also have R = the identity and P[1:3,1:3] = K.
00437 # For a stereo pair, the fourth column [Tx Ty 0]' is related to the
00438 # position of the optical center of the second camera in the first
00439 # camera's frame. We assume Tz = 0 so both cameras are in the same
00440 # stereo image plane. The first camera always has Tx = Ty = 0. For
00441 # the right (second) camera of a horizontal stereo pair, Ty = 0 and
00442 # Tx = -fx' * B, where B is the baseline between the cameras.
00443 # Given a 3D point [X Y Z]', the projection (x, y) of the point onto
00444 # the rectified image is given by:
00445 # [u v w]' = P * [X Y Z 1]'
00446 # x = u / w
00447 # y = v / w
00448 # This holds for both images of a stereo pair.
00449 float64[12] P # 3x4 row-major matrix
00450
00451
00452 #######################################################################
00453 # Operational Parameters #
00454 #######################################################################
00455 # These define the image region actually captured by the camera #
00456 # driver. Although they affect the geometry of the output image, they #
00457 # may be changed freely without recalibrating the camera. #
00458 #######################################################################
00459
00460 # Binning refers here to any camera setting which combines rectangular
00461 # neighborhoods of pixels into larger "super-pixels." It reduces the
00462 # resolution of the output image to
00463 # (width / binning_x) x (height / binning_y).
00464 # The default values binning_x = binning_y = 0 is considered the same
00465 # as binning_x = binning_y = 1 (no subsampling).
00466 uint32 binning_x
00467 uint32 binning_y
00468
00469 # Region of interest (subwindow of full camera resolution), given in
00470 # full resolution (unbinned) image coordinates. A particular ROI
00471 # always denotes the same window of pixels on the camera sensor,
00472 # regardless of binning settings.
00473 # The default setting of roi (all values 0) is considered the same as
00474 # full resolution (roi.width = width, roi.height = height).
00475 RegionOfInterest roi
00476
00477 ================================================================================
00478 MSG: sensor_msgs/RegionOfInterest
00479 # This message is used to specify a region of interest within an image.
00480 #
00481 # When used to specify the ROI setting of the camera when the image was
00482 # taken, the height and width fields should either match the height and
00483 # width fields for the associated image; or height = width = 0
00484 # indicates that the full resolution image was captured.
00485
00486 uint32 x_offset # Leftmost pixel of the ROI
00487 # (0 if the ROI includes the left edge of the image)
00488 uint32 y_offset # Topmost pixel of the ROI
00489 # (0 if the ROI includes the top edge of the image)
00490 uint32 height # Height of ROI
00491 uint32 width # Width of ROI
00492
00493 # True if a distinct rectified ROI should be calculated from the "raw"
00494 # ROI in this message. Typically this should be False if the full image
00495 # is captured (ROI not used), and True if a subwindow is captured (ROI
00496 # used).
00497 bool do_rectify
00498
00499 ================================================================================
00500 MSG: geometry_msgs/Vector3
00501 # This represents a vector in free space.
00502
00503 float64 x
00504 float64 y
00505 float64 z
00506 ================================================================================
00507 MSG: pr2_object_manipulation_msgs/IMGUIAdvancedOptions
00508
00509 bool reactive_grasping
00510 bool reactive_force
00511 bool reactive_place
00512 int32 lift_steps
00513 int32 retreat_steps
00514 int32 lift_direction_choice
00515 int32 desired_approach
00516 int32 min_approach
00517 float32 max_contact_force
00518 bool find_alternatives
00519 bool always_plan_grasps
00520 bool cycle_gripper_opening
00521
00522 ================================================================================
00523 MSG: pr2_object_manipulation_msgs/IMGUICommand
00524
00525 int32 PICKUP = 0
00526 int32 PLACE = 1
00527 int32 PLANNED_MOVE = 2
00528 int32 RESET = 3
00529 int32 MOVE_ARM = 4
00530 int32 LOOK_AT_TABLE = 5
00531 int32 MODEL_OBJECT = 6
00532 int32 MOVE_GRIPPER = 7
00533 int32 SCRIPTED_ACTION = 8
00534 int32 STOP_NAV = 9
00535
00536 int32 command
00537 string script_name
00538 string script_group_name
00539
00540 ================================================================================
00541 MSG: pr2_object_manipulation_msgs/IMGUIActionResult
00542 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00543
00544 Header header
00545 actionlib_msgs/GoalStatus status
00546 IMGUIResult result
00547
00548 ================================================================================
00549 MSG: actionlib_msgs/GoalStatus
00550 GoalID goal_id
00551 uint8 status
00552 uint8 PENDING = 0 # The goal has yet to be processed by the action server
00553 uint8 ACTIVE = 1 # The goal is currently being processed by the action server
00554 uint8 PREEMPTED = 2 # The goal received a cancel request after it started executing
00555 # and has since completed its execution (Terminal State)
00556 uint8 SUCCEEDED = 3 # The goal was achieved successfully by the action server (Terminal State)
00557 uint8 ABORTED = 4 # The goal was aborted during execution by the action server due
00558 # to some failure (Terminal State)
00559 uint8 REJECTED = 5 # The goal was rejected by the action server without being processed,
00560 # because the goal was unattainable or invalid (Terminal State)
00561 uint8 PREEMPTING = 6 # The goal received a cancel request after it started executing
00562 # and has not yet completed execution
00563 uint8 RECALLING = 7 # The goal received a cancel request before it started executing,
00564 # but the action server has not yet confirmed that the goal is canceled
00565 uint8 RECALLED = 8 # The goal received a cancel request before it started executing
00566 # and was successfully cancelled (Terminal State)
00567 uint8 LOST = 9 # An action client can determine that a goal is LOST. This should not be
00568 # sent over the wire by an action server
00569
00570 #Allow for the user to associate a string with GoalStatus for debugging
00571 string text
00572
00573
00574 ================================================================================
00575 MSG: pr2_object_manipulation_msgs/IMGUIResult
00576 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00577
00578 #empty result
00579 object_manipulation_msgs/ManipulationResult result
00580
00581
00582 ================================================================================
00583 MSG: object_manipulation_msgs/ManipulationResult
00584 # Result codes for manipulation tasks
00585
00586 # task completed as expected
00587 # generally means you can proceed as planned
00588 int32 SUCCESS = 1
00589
00590 # task not possible (e.g. out of reach or obstacles in the way)
00591 # generally means that the world was not disturbed, so you can try another task
00592 int32 UNFEASIBLE = -1
00593
00594 # task was thought possible, but failed due to unexpected events during execution
00595 # it is likely that the world was disturbed, so you are encouraged to refresh
00596 # your sensed world model before proceeding to another task
00597 int32 FAILED = -2
00598
00599 # a lower level error prevented task completion (e.g. joint controller not responding)
00600 # generally requires human attention
00601 int32 ERROR = -3
00602
00603 # means that at some point during execution we ended up in a state that the collision-aware
00604 # arm navigation module will not move out of. The world was likely not disturbed, but you
00605 # probably need a new collision map to move the arm out of the stuck position
00606 int32 ARM_MOVEMENT_PREVENTED = -4
00607
00608 # specific to grasp actions
00609 # the object was grasped successfully, but the lift attempt could not achieve the minimum lift distance requested
00610 # it is likely that the collision environment will see collisions between the hand/object and the support surface
00611 int32 LIFT_FAILED = -5
00612
00613 # specific to place actions
00614 # the object was placed successfully, but the retreat attempt could not achieve the minimum retreat distance requested
00615 # it is likely that the collision environment will see collisions between the hand and the object
00616 int32 RETREAT_FAILED = -6
00617
00618 # indicates that somewhere along the line a human said "wait, stop, this is bad, go back and do something else"
00619 int32 CANCELLED = -7
00620
00621 # the actual value of this error code
00622 int32 value
00623
00624 ================================================================================
00625 MSG: pr2_object_manipulation_msgs/IMGUIActionFeedback
00626 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00627
00628 Header header
00629 actionlib_msgs/GoalStatus status
00630 IMGUIFeedback feedback
00631
00632 ================================================================================
00633 MSG: pr2_object_manipulation_msgs/IMGUIFeedback
00634 # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
00635
00636 string status
00637
00638
00639 """
00640 __slots__ = ['action_goal','action_result','action_feedback']
00641 _slot_types = ['pr2_object_manipulation_msgs/IMGUIActionGoal','pr2_object_manipulation_msgs/IMGUIActionResult','pr2_object_manipulation_msgs/IMGUIActionFeedback']
00642
00643 def __init__(self, *args, **kwds):
00644 """
00645 Constructor. Any message fields that are implicitly/explicitly
00646 set to None will be assigned a default value. The recommend
00647 use is keyword arguments as this is more robust to future message
00648 changes. You cannot mix in-order arguments and keyword arguments.
00649
00650 The available fields are:
00651 action_goal,action_result,action_feedback
00652
00653 :param args: complete set of field values, in .msg order
00654 :param kwds: use keyword arguments corresponding to message field names
00655 to set specific fields.
00656 """
00657 if args or kwds:
00658 super(IMGUIAction, self).__init__(*args, **kwds)
00659 #message fields cannot be None, assign default values for those that are
00660 if self.action_goal is None:
00661 self.action_goal = pr2_object_manipulation_msgs.msg.IMGUIActionGoal()
00662 if self.action_result is None:
00663 self.action_result = pr2_object_manipulation_msgs.msg.IMGUIActionResult()
00664 if self.action_feedback is None:
00665 self.action_feedback = pr2_object_manipulation_msgs.msg.IMGUIActionFeedback()
00666 else:
00667 self.action_goal = pr2_object_manipulation_msgs.msg.IMGUIActionGoal()
00668 self.action_result = pr2_object_manipulation_msgs.msg.IMGUIActionResult()
00669 self.action_feedback = pr2_object_manipulation_msgs.msg.IMGUIActionFeedback()
00670
00671 def _get_types(self):
00672 """
00673 internal API method
00674 """
00675 return self._slot_types
00676
00677 def serialize(self, buff):
00678 """
00679 serialize message into buffer
00680 :param buff: buffer, ``StringIO``
00681 """
00682 try:
00683 _x = self
00684 buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
00685 _x = self.action_goal.header.frame_id
00686 length = len(_x)
00687 if python3 or type(_x) == unicode:
00688 _x = _x.encode('utf-8')
00689 length = len(_x)
00690 buff.write(struct.pack('<I%ss'%length, length, _x))
00691 _x = self
00692 buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
00693 _x = self.action_goal.goal_id.id
00694 length = len(_x)
00695 if python3 or type(_x) == unicode:
00696 _x = _x.encode('utf-8')
00697 length = len(_x)
00698 buff.write(struct.pack('<I%ss'%length, length, _x))
00699 _x = self
00700 buff.write(_struct_B6i.pack(_x.action_goal.goal.options.collision_checked, _x.action_goal.goal.options.grasp_selection, _x.action_goal.goal.options.arm_selection, _x.action_goal.goal.options.reset_choice, _x.action_goal.goal.options.arm_action_choice, _x.action_goal.goal.options.arm_planner_choice, _x.action_goal.goal.options.gripper_slider_position))
00701 _x = self.action_goal.goal.options.selected_object.reference_frame_id
00702 length = len(_x)
00703 if python3 or type(_x) == unicode:
00704 _x = _x.encode('utf-8')
00705 length = len(_x)
00706 buff.write(struct.pack('<I%ss'%length, length, _x))
00707 length = len(self.action_goal.goal.options.selected_object.potential_models)
00708 buff.write(_struct_I.pack(length))
00709 for val1 in self.action_goal.goal.options.selected_object.potential_models:
00710 buff.write(_struct_i.pack(val1.model_id))
00711 _v1 = val1.pose
00712 _v2 = _v1.header
00713 buff.write(_struct_I.pack(_v2.seq))
00714 _v3 = _v2.stamp
00715 _x = _v3
00716 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00717 _x = _v2.frame_id
00718 length = len(_x)
00719 if python3 or type(_x) == unicode:
00720 _x = _x.encode('utf-8')
00721 length = len(_x)
00722 buff.write(struct.pack('<I%ss'%length, length, _x))
00723 _v4 = _v1.pose
00724 _v5 = _v4.position
00725 _x = _v5
00726 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00727 _v6 = _v4.orientation
00728 _x = _v6
00729 buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00730 buff.write(_struct_f.pack(val1.confidence))
00731 _x = val1.detector_name
00732 length = len(_x)
00733 if python3 or type(_x) == unicode:
00734 _x = _x.encode('utf-8')
00735 length = len(_x)
00736 buff.write(struct.pack('<I%ss'%length, length, _x))
00737 _x = self
00738 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.cluster.header.seq, _x.action_goal.goal.options.selected_object.cluster.header.stamp.secs, _x.action_goal.goal.options.selected_object.cluster.header.stamp.nsecs))
00739 _x = self.action_goal.goal.options.selected_object.cluster.header.frame_id
00740 length = len(_x)
00741 if python3 or type(_x) == unicode:
00742 _x = _x.encode('utf-8')
00743 length = len(_x)
00744 buff.write(struct.pack('<I%ss'%length, length, _x))
00745 length = len(self.action_goal.goal.options.selected_object.cluster.points)
00746 buff.write(_struct_I.pack(length))
00747 for val1 in self.action_goal.goal.options.selected_object.cluster.points:
00748 _x = val1
00749 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00750 length = len(self.action_goal.goal.options.selected_object.cluster.channels)
00751 buff.write(_struct_I.pack(length))
00752 for val1 in self.action_goal.goal.options.selected_object.cluster.channels:
00753 _x = val1.name
00754 length = len(_x)
00755 if python3 or type(_x) == unicode:
00756 _x = _x.encode('utf-8')
00757 length = len(_x)
00758 buff.write(struct.pack('<I%ss'%length, length, _x))
00759 length = len(val1.values)
00760 buff.write(_struct_I.pack(length))
00761 pattern = '<%sf'%length
00762 buff.write(struct.pack(pattern, *val1.values))
00763 _x = self
00764 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.cloud.header.seq, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.nsecs))
00765 _x = self.action_goal.goal.options.selected_object.region.cloud.header.frame_id
00766 length = len(_x)
00767 if python3 or type(_x) == unicode:
00768 _x = _x.encode('utf-8')
00769 length = len(_x)
00770 buff.write(struct.pack('<I%ss'%length, length, _x))
00771 _x = self
00772 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.cloud.height, _x.action_goal.goal.options.selected_object.region.cloud.width))
00773 length = len(self.action_goal.goal.options.selected_object.region.cloud.fields)
00774 buff.write(_struct_I.pack(length))
00775 for val1 in self.action_goal.goal.options.selected_object.region.cloud.fields:
00776 _x = val1.name
00777 length = len(_x)
00778 if python3 or type(_x) == unicode:
00779 _x = _x.encode('utf-8')
00780 length = len(_x)
00781 buff.write(struct.pack('<I%ss'%length, length, _x))
00782 _x = val1
00783 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
00784 _x = self
00785 buff.write(_struct_B2I.pack(_x.action_goal.goal.options.selected_object.region.cloud.is_bigendian, _x.action_goal.goal.options.selected_object.region.cloud.point_step, _x.action_goal.goal.options.selected_object.region.cloud.row_step))
00786 _x = self.action_goal.goal.options.selected_object.region.cloud.data
00787 length = len(_x)
00788 # - if encoded as a list instead, serialize as bytes instead of string
00789 if type(_x) in [list, tuple]:
00790 buff.write(struct.pack('<I%sB'%length, length, *_x))
00791 else:
00792 buff.write(struct.pack('<I%ss'%length, length, _x))
00793 buff.write(_struct_B.pack(self.action_goal.goal.options.selected_object.region.cloud.is_dense))
00794 length = len(self.action_goal.goal.options.selected_object.region.mask)
00795 buff.write(_struct_I.pack(length))
00796 pattern = '<%si'%length
00797 buff.write(struct.pack(pattern, *self.action_goal.goal.options.selected_object.region.mask))
00798 _x = self
00799 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.image.header.seq, _x.action_goal.goal.options.selected_object.region.image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.image.header.stamp.nsecs))
00800 _x = self.action_goal.goal.options.selected_object.region.image.header.frame_id
00801 length = len(_x)
00802 if python3 or type(_x) == unicode:
00803 _x = _x.encode('utf-8')
00804 length = len(_x)
00805 buff.write(struct.pack('<I%ss'%length, length, _x))
00806 _x = self
00807 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.image.height, _x.action_goal.goal.options.selected_object.region.image.width))
00808 _x = self.action_goal.goal.options.selected_object.region.image.encoding
00809 length = len(_x)
00810 if python3 or type(_x) == unicode:
00811 _x = _x.encode('utf-8')
00812 length = len(_x)
00813 buff.write(struct.pack('<I%ss'%length, length, _x))
00814 _x = self
00815 buff.write(_struct_BI.pack(_x.action_goal.goal.options.selected_object.region.image.is_bigendian, _x.action_goal.goal.options.selected_object.region.image.step))
00816 _x = self.action_goal.goal.options.selected_object.region.image.data
00817 length = len(_x)
00818 # - if encoded as a list instead, serialize as bytes instead of string
00819 if type(_x) in [list, tuple]:
00820 buff.write(struct.pack('<I%sB'%length, length, *_x))
00821 else:
00822 buff.write(struct.pack('<I%ss'%length, length, _x))
00823 _x = self
00824 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.disparity_image.header.seq, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.nsecs))
00825 _x = self.action_goal.goal.options.selected_object.region.disparity_image.header.frame_id
00826 length = len(_x)
00827 if python3 or type(_x) == unicode:
00828 _x = _x.encode('utf-8')
00829 length = len(_x)
00830 buff.write(struct.pack('<I%ss'%length, length, _x))
00831 _x = self
00832 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.disparity_image.height, _x.action_goal.goal.options.selected_object.region.disparity_image.width))
00833 _x = self.action_goal.goal.options.selected_object.region.disparity_image.encoding
00834 length = len(_x)
00835 if python3 or type(_x) == unicode:
00836 _x = _x.encode('utf-8')
00837 length = len(_x)
00838 buff.write(struct.pack('<I%ss'%length, length, _x))
00839 _x = self
00840 buff.write(_struct_BI.pack(_x.action_goal.goal.options.selected_object.region.disparity_image.is_bigendian, _x.action_goal.goal.options.selected_object.region.disparity_image.step))
00841 _x = self.action_goal.goal.options.selected_object.region.disparity_image.data
00842 length = len(_x)
00843 # - if encoded as a list instead, serialize as bytes instead of string
00844 if type(_x) in [list, tuple]:
00845 buff.write(struct.pack('<I%sB'%length, length, *_x))
00846 else:
00847 buff.write(struct.pack('<I%ss'%length, length, _x))
00848 _x = self
00849 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.cam_info.header.seq, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.nsecs))
00850 _x = self.action_goal.goal.options.selected_object.region.cam_info.header.frame_id
00851 length = len(_x)
00852 if python3 or type(_x) == unicode:
00853 _x = _x.encode('utf-8')
00854 length = len(_x)
00855 buff.write(struct.pack('<I%ss'%length, length, _x))
00856 _x = self
00857 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.cam_info.height, _x.action_goal.goal.options.selected_object.region.cam_info.width))
00858 _x = self.action_goal.goal.options.selected_object.region.cam_info.distortion_model
00859 length = len(_x)
00860 if python3 or type(_x) == unicode:
00861 _x = _x.encode('utf-8')
00862 length = len(_x)
00863 buff.write(struct.pack('<I%ss'%length, length, _x))
00864 length = len(self.action_goal.goal.options.selected_object.region.cam_info.D)
00865 buff.write(_struct_I.pack(length))
00866 pattern = '<%sd'%length
00867 buff.write(struct.pack(pattern, *self.action_goal.goal.options.selected_object.region.cam_info.D))
00868 buff.write(_struct_9d.pack(*self.action_goal.goal.options.selected_object.region.cam_info.K))
00869 buff.write(_struct_9d.pack(*self.action_goal.goal.options.selected_object.region.cam_info.R))
00870 buff.write(_struct_12d.pack(*self.action_goal.goal.options.selected_object.region.cam_info.P))
00871 _x = self
00872 buff.write(_struct_6IB3I.pack(_x.action_goal.goal.options.selected_object.region.cam_info.binning_x, _x.action_goal.goal.options.selected_object.region.cam_info.binning_y, _x.action_goal.goal.options.selected_object.region.cam_info.roi.x_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.y_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.height, _x.action_goal.goal.options.selected_object.region.cam_info.roi.width, _x.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.seq, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.nsecs))
00873 _x = self.action_goal.goal.options.selected_object.region.roi_box_pose.header.frame_id
00874 length = len(_x)
00875 if python3 or type(_x) == unicode:
00876 _x = _x.encode('utf-8')
00877 length = len(_x)
00878 buff.write(struct.pack('<I%ss'%length, length, _x))
00879 _x = self
00880 buff.write(_struct_10d.pack(_x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.w, _x.action_goal.goal.options.selected_object.region.roi_box_dims.x, _x.action_goal.goal.options.selected_object.region.roi_box_dims.y, _x.action_goal.goal.options.selected_object.region.roi_box_dims.z))
00881 _x = self.action_goal.goal.options.selected_object.collision_name
00882 length = len(_x)
00883 if python3 or type(_x) == unicode:
00884 _x = _x.encode('utf-8')
00885 length = len(_x)
00886 buff.write(struct.pack('<I%ss'%length, length, _x))
00887 length = len(self.action_goal.goal.options.movable_obstacles)
00888 buff.write(_struct_I.pack(length))
00889 for val1 in self.action_goal.goal.options.movable_obstacles:
00890 _x = val1.reference_frame_id
00891 length = len(_x)
00892 if python3 or type(_x) == unicode:
00893 _x = _x.encode('utf-8')
00894 length = len(_x)
00895 buff.write(struct.pack('<I%ss'%length, length, _x))
00896 length = len(val1.potential_models)
00897 buff.write(_struct_I.pack(length))
00898 for val2 in val1.potential_models:
00899 buff.write(_struct_i.pack(val2.model_id))
00900 _v7 = val2.pose
00901 _v8 = _v7.header
00902 buff.write(_struct_I.pack(_v8.seq))
00903 _v9 = _v8.stamp
00904 _x = _v9
00905 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00906 _x = _v8.frame_id
00907 length = len(_x)
00908 if python3 or type(_x) == unicode:
00909 _x = _x.encode('utf-8')
00910 length = len(_x)
00911 buff.write(struct.pack('<I%ss'%length, length, _x))
00912 _v10 = _v7.pose
00913 _v11 = _v10.position
00914 _x = _v11
00915 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00916 _v12 = _v10.orientation
00917 _x = _v12
00918 buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00919 buff.write(_struct_f.pack(val2.confidence))
00920 _x = val2.detector_name
00921 length = len(_x)
00922 if python3 or type(_x) == unicode:
00923 _x = _x.encode('utf-8')
00924 length = len(_x)
00925 buff.write(struct.pack('<I%ss'%length, length, _x))
00926 _v13 = val1.cluster
00927 _v14 = _v13.header
00928 buff.write(_struct_I.pack(_v14.seq))
00929 _v15 = _v14.stamp
00930 _x = _v15
00931 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00932 _x = _v14.frame_id
00933 length = len(_x)
00934 if python3 or type(_x) == unicode:
00935 _x = _x.encode('utf-8')
00936 length = len(_x)
00937 buff.write(struct.pack('<I%ss'%length, length, _x))
00938 length = len(_v13.points)
00939 buff.write(_struct_I.pack(length))
00940 for val3 in _v13.points:
00941 _x = val3
00942 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
00943 length = len(_v13.channels)
00944 buff.write(_struct_I.pack(length))
00945 for val3 in _v13.channels:
00946 _x = val3.name
00947 length = len(_x)
00948 if python3 or type(_x) == unicode:
00949 _x = _x.encode('utf-8')
00950 length = len(_x)
00951 buff.write(struct.pack('<I%ss'%length, length, _x))
00952 length = len(val3.values)
00953 buff.write(_struct_I.pack(length))
00954 pattern = '<%sf'%length
00955 buff.write(struct.pack(pattern, *val3.values))
00956 _v16 = val1.region
00957 _v17 = _v16.cloud
00958 _v18 = _v17.header
00959 buff.write(_struct_I.pack(_v18.seq))
00960 _v19 = _v18.stamp
00961 _x = _v19
00962 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00963 _x = _v18.frame_id
00964 length = len(_x)
00965 if python3 or type(_x) == unicode:
00966 _x = _x.encode('utf-8')
00967 length = len(_x)
00968 buff.write(struct.pack('<I%ss'%length, length, _x))
00969 _x = _v17
00970 buff.write(_struct_2I.pack(_x.height, _x.width))
00971 length = len(_v17.fields)
00972 buff.write(_struct_I.pack(length))
00973 for val4 in _v17.fields:
00974 _x = val4.name
00975 length = len(_x)
00976 if python3 or type(_x) == unicode:
00977 _x = _x.encode('utf-8')
00978 length = len(_x)
00979 buff.write(struct.pack('<I%ss'%length, length, _x))
00980 _x = val4
00981 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
00982 _x = _v17
00983 buff.write(_struct_B2I.pack(_x.is_bigendian, _x.point_step, _x.row_step))
00984 _x = _v17.data
00985 length = len(_x)
00986 # - if encoded as a list instead, serialize as bytes instead of string
00987 if type(_x) in [list, tuple]:
00988 buff.write(struct.pack('<I%sB'%length, length, *_x))
00989 else:
00990 buff.write(struct.pack('<I%ss'%length, length, _x))
00991 buff.write(_struct_B.pack(_v17.is_dense))
00992 length = len(_v16.mask)
00993 buff.write(_struct_I.pack(length))
00994 pattern = '<%si'%length
00995 buff.write(struct.pack(pattern, *_v16.mask))
00996 _v20 = _v16.image
00997 _v21 = _v20.header
00998 buff.write(_struct_I.pack(_v21.seq))
00999 _v22 = _v21.stamp
01000 _x = _v22
01001 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
01002 _x = _v21.frame_id
01003 length = len(_x)
01004 if python3 or type(_x) == unicode:
01005 _x = _x.encode('utf-8')
01006 length = len(_x)
01007 buff.write(struct.pack('<I%ss'%length, length, _x))
01008 _x = _v20
01009 buff.write(_struct_2I.pack(_x.height, _x.width))
01010 _x = _v20.encoding
01011 length = len(_x)
01012 if python3 or type(_x) == unicode:
01013 _x = _x.encode('utf-8')
01014 length = len(_x)
01015 buff.write(struct.pack('<I%ss'%length, length, _x))
01016 _x = _v20
01017 buff.write(_struct_BI.pack(_x.is_bigendian, _x.step))
01018 _x = _v20.data
01019 length = len(_x)
01020 # - if encoded as a list instead, serialize as bytes instead of string
01021 if type(_x) in [list, tuple]:
01022 buff.write(struct.pack('<I%sB'%length, length, *_x))
01023 else:
01024 buff.write(struct.pack('<I%ss'%length, length, _x))
01025 _v23 = _v16.disparity_image
01026 _v24 = _v23.header
01027 buff.write(_struct_I.pack(_v24.seq))
01028 _v25 = _v24.stamp
01029 _x = _v25
01030 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
01031 _x = _v24.frame_id
01032 length = len(_x)
01033 if python3 or type(_x) == unicode:
01034 _x = _x.encode('utf-8')
01035 length = len(_x)
01036 buff.write(struct.pack('<I%ss'%length, length, _x))
01037 _x = _v23
01038 buff.write(_struct_2I.pack(_x.height, _x.width))
01039 _x = _v23.encoding
01040 length = len(_x)
01041 if python3 or type(_x) == unicode:
01042 _x = _x.encode('utf-8')
01043 length = len(_x)
01044 buff.write(struct.pack('<I%ss'%length, length, _x))
01045 _x = _v23
01046 buff.write(_struct_BI.pack(_x.is_bigendian, _x.step))
01047 _x = _v23.data
01048 length = len(_x)
01049 # - if encoded as a list instead, serialize as bytes instead of string
01050 if type(_x) in [list, tuple]:
01051 buff.write(struct.pack('<I%sB'%length, length, *_x))
01052 else:
01053 buff.write(struct.pack('<I%ss'%length, length, _x))
01054 _v26 = _v16.cam_info
01055 _v27 = _v26.header
01056 buff.write(_struct_I.pack(_v27.seq))
01057 _v28 = _v27.stamp
01058 _x = _v28
01059 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
01060 _x = _v27.frame_id
01061 length = len(_x)
01062 if python3 or type(_x) == unicode:
01063 _x = _x.encode('utf-8')
01064 length = len(_x)
01065 buff.write(struct.pack('<I%ss'%length, length, _x))
01066 _x = _v26
01067 buff.write(_struct_2I.pack(_x.height, _x.width))
01068 _x = _v26.distortion_model
01069 length = len(_x)
01070 if python3 or type(_x) == unicode:
01071 _x = _x.encode('utf-8')
01072 length = len(_x)
01073 buff.write(struct.pack('<I%ss'%length, length, _x))
01074 length = len(_v26.D)
01075 buff.write(_struct_I.pack(length))
01076 pattern = '<%sd'%length
01077 buff.write(struct.pack(pattern, *_v26.D))
01078 buff.write(_struct_9d.pack(*_v26.K))
01079 buff.write(_struct_9d.pack(*_v26.R))
01080 buff.write(_struct_12d.pack(*_v26.P))
01081 _x = _v26
01082 buff.write(_struct_2I.pack(_x.binning_x, _x.binning_y))
01083 _v29 = _v26.roi
01084 _x = _v29
01085 buff.write(_struct_4IB.pack(_x.x_offset, _x.y_offset, _x.height, _x.width, _x.do_rectify))
01086 _v30 = _v16.roi_box_pose
01087 _v31 = _v30.header
01088 buff.write(_struct_I.pack(_v31.seq))
01089 _v32 = _v31.stamp
01090 _x = _v32
01091 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
01092 _x = _v31.frame_id
01093 length = len(_x)
01094 if python3 or type(_x) == unicode:
01095 _x = _x.encode('utf-8')
01096 length = len(_x)
01097 buff.write(struct.pack('<I%ss'%length, length, _x))
01098 _v33 = _v30.pose
01099 _v34 = _v33.position
01100 _x = _v34
01101 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
01102 _v35 = _v33.orientation
01103 _x = _v35
01104 buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
01105 _v36 = _v16.roi_box_dims
01106 _x = _v36
01107 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
01108 _x = val1.collision_name
01109 length = len(_x)
01110 if python3 or type(_x) == unicode:
01111 _x = _x.encode('utf-8')
01112 length = len(_x)
01113 buff.write(struct.pack('<I%ss'%length, length, _x))
01114 _x = self
01115 buff.write(_struct_3B5if3Bi.pack(_x.action_goal.goal.options.adv_options.reactive_grasping, _x.action_goal.goal.options.adv_options.reactive_force, _x.action_goal.goal.options.adv_options.reactive_place, _x.action_goal.goal.options.adv_options.lift_steps, _x.action_goal.goal.options.adv_options.retreat_steps, _x.action_goal.goal.options.adv_options.lift_direction_choice, _x.action_goal.goal.options.adv_options.desired_approach, _x.action_goal.goal.options.adv_options.min_approach, _x.action_goal.goal.options.adv_options.max_contact_force, _x.action_goal.goal.options.adv_options.find_alternatives, _x.action_goal.goal.options.adv_options.always_plan_grasps, _x.action_goal.goal.options.adv_options.cycle_gripper_opening, _x.action_goal.goal.command.command))
01116 _x = self.action_goal.goal.command.script_name
01117 length = len(_x)
01118 if python3 or type(_x) == unicode:
01119 _x = _x.encode('utf-8')
01120 length = len(_x)
01121 buff.write(struct.pack('<I%ss'%length, length, _x))
01122 _x = self.action_goal.goal.command.script_group_name
01123 length = len(_x)
01124 if python3 or type(_x) == unicode:
01125 _x = _x.encode('utf-8')
01126 length = len(_x)
01127 buff.write(struct.pack('<I%ss'%length, length, _x))
01128 _x = self
01129 buff.write(_struct_3I.pack(_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
01130 _x = self.action_result.header.frame_id
01131 length = len(_x)
01132 if python3 or type(_x) == unicode:
01133 _x = _x.encode('utf-8')
01134 length = len(_x)
01135 buff.write(struct.pack('<I%ss'%length, length, _x))
01136 _x = self
01137 buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
01138 _x = self.action_result.status.goal_id.id
01139 length = len(_x)
01140 if python3 or type(_x) == unicode:
01141 _x = _x.encode('utf-8')
01142 length = len(_x)
01143 buff.write(struct.pack('<I%ss'%length, length, _x))
01144 buff.write(_struct_B.pack(self.action_result.status.status))
01145 _x = self.action_result.status.text
01146 length = len(_x)
01147 if python3 or type(_x) == unicode:
01148 _x = _x.encode('utf-8')
01149 length = len(_x)
01150 buff.write(struct.pack('<I%ss'%length, length, _x))
01151 _x = self
01152 buff.write(_struct_i3I.pack(_x.action_result.result.result.value, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
01153 _x = self.action_feedback.header.frame_id
01154 length = len(_x)
01155 if python3 or type(_x) == unicode:
01156 _x = _x.encode('utf-8')
01157 length = len(_x)
01158 buff.write(struct.pack('<I%ss'%length, length, _x))
01159 _x = self
01160 buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
01161 _x = self.action_feedback.status.goal_id.id
01162 length = len(_x)
01163 if python3 or type(_x) == unicode:
01164 _x = _x.encode('utf-8')
01165 length = len(_x)
01166 buff.write(struct.pack('<I%ss'%length, length, _x))
01167 buff.write(_struct_B.pack(self.action_feedback.status.status))
01168 _x = self.action_feedback.status.text
01169 length = len(_x)
01170 if python3 or type(_x) == unicode:
01171 _x = _x.encode('utf-8')
01172 length = len(_x)
01173 buff.write(struct.pack('<I%ss'%length, length, _x))
01174 _x = self.action_feedback.feedback.status
01175 length = len(_x)
01176 if python3 or type(_x) == unicode:
01177 _x = _x.encode('utf-8')
01178 length = len(_x)
01179 buff.write(struct.pack('<I%ss'%length, length, _x))
01180 except struct.error as se: self._check_types(se)
01181 except TypeError as te: self._check_types(te)
01182
01183 def deserialize(self, str):
01184 """
01185 unpack serialized message in str into this message instance
01186 :param str: byte array of serialized message, ``str``
01187 """
01188 try:
01189 if self.action_goal is None:
01190 self.action_goal = pr2_object_manipulation_msgs.msg.IMGUIActionGoal()
01191 if self.action_result is None:
01192 self.action_result = pr2_object_manipulation_msgs.msg.IMGUIActionResult()
01193 if self.action_feedback is None:
01194 self.action_feedback = pr2_object_manipulation_msgs.msg.IMGUIActionFeedback()
01195 end = 0
01196 _x = self
01197 start = end
01198 end += 12
01199 (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01200 start = end
01201 end += 4
01202 (length,) = _struct_I.unpack(str[start:end])
01203 start = end
01204 end += length
01205 if python3:
01206 self.action_goal.header.frame_id = str[start:end].decode('utf-8')
01207 else:
01208 self.action_goal.header.frame_id = str[start:end]
01209 _x = self
01210 start = end
01211 end += 8
01212 (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
01213 start = end
01214 end += 4
01215 (length,) = _struct_I.unpack(str[start:end])
01216 start = end
01217 end += length
01218 if python3:
01219 self.action_goal.goal_id.id = str[start:end].decode('utf-8')
01220 else:
01221 self.action_goal.goal_id.id = str[start:end]
01222 _x = self
01223 start = end
01224 end += 25
01225 (_x.action_goal.goal.options.collision_checked, _x.action_goal.goal.options.grasp_selection, _x.action_goal.goal.options.arm_selection, _x.action_goal.goal.options.reset_choice, _x.action_goal.goal.options.arm_action_choice, _x.action_goal.goal.options.arm_planner_choice, _x.action_goal.goal.options.gripper_slider_position,) = _struct_B6i.unpack(str[start:end])
01226 self.action_goal.goal.options.collision_checked = bool(self.action_goal.goal.options.collision_checked)
01227 start = end
01228 end += 4
01229 (length,) = _struct_I.unpack(str[start:end])
01230 start = end
01231 end += length
01232 if python3:
01233 self.action_goal.goal.options.selected_object.reference_frame_id = str[start:end].decode('utf-8')
01234 else:
01235 self.action_goal.goal.options.selected_object.reference_frame_id = str[start:end]
01236 start = end
01237 end += 4
01238 (length,) = _struct_I.unpack(str[start:end])
01239 self.action_goal.goal.options.selected_object.potential_models = []
01240 for i in range(0, length):
01241 val1 = household_objects_database_msgs.msg.DatabaseModelPose()
01242 start = end
01243 end += 4
01244 (val1.model_id,) = _struct_i.unpack(str[start:end])
01245 _v37 = val1.pose
01246 _v38 = _v37.header
01247 start = end
01248 end += 4
01249 (_v38.seq,) = _struct_I.unpack(str[start:end])
01250 _v39 = _v38.stamp
01251 _x = _v39
01252 start = end
01253 end += 8
01254 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01255 start = end
01256 end += 4
01257 (length,) = _struct_I.unpack(str[start:end])
01258 start = end
01259 end += length
01260 if python3:
01261 _v38.frame_id = str[start:end].decode('utf-8')
01262 else:
01263 _v38.frame_id = str[start:end]
01264 _v40 = _v37.pose
01265 _v41 = _v40.position
01266 _x = _v41
01267 start = end
01268 end += 24
01269 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
01270 _v42 = _v40.orientation
01271 _x = _v42
01272 start = end
01273 end += 32
01274 (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
01275 start = end
01276 end += 4
01277 (val1.confidence,) = _struct_f.unpack(str[start:end])
01278 start = end
01279 end += 4
01280 (length,) = _struct_I.unpack(str[start:end])
01281 start = end
01282 end += length
01283 if python3:
01284 val1.detector_name = str[start:end].decode('utf-8')
01285 else:
01286 val1.detector_name = str[start:end]
01287 self.action_goal.goal.options.selected_object.potential_models.append(val1)
01288 _x = self
01289 start = end
01290 end += 12
01291 (_x.action_goal.goal.options.selected_object.cluster.header.seq, _x.action_goal.goal.options.selected_object.cluster.header.stamp.secs, _x.action_goal.goal.options.selected_object.cluster.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01292 start = end
01293 end += 4
01294 (length,) = _struct_I.unpack(str[start:end])
01295 start = end
01296 end += length
01297 if python3:
01298 self.action_goal.goal.options.selected_object.cluster.header.frame_id = str[start:end].decode('utf-8')
01299 else:
01300 self.action_goal.goal.options.selected_object.cluster.header.frame_id = str[start:end]
01301 start = end
01302 end += 4
01303 (length,) = _struct_I.unpack(str[start:end])
01304 self.action_goal.goal.options.selected_object.cluster.points = []
01305 for i in range(0, length):
01306 val1 = geometry_msgs.msg.Point32()
01307 _x = val1
01308 start = end
01309 end += 12
01310 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
01311 self.action_goal.goal.options.selected_object.cluster.points.append(val1)
01312 start = end
01313 end += 4
01314 (length,) = _struct_I.unpack(str[start:end])
01315 self.action_goal.goal.options.selected_object.cluster.channels = []
01316 for i in range(0, length):
01317 val1 = sensor_msgs.msg.ChannelFloat32()
01318 start = end
01319 end += 4
01320 (length,) = _struct_I.unpack(str[start:end])
01321 start = end
01322 end += length
01323 if python3:
01324 val1.name = str[start:end].decode('utf-8')
01325 else:
01326 val1.name = str[start:end]
01327 start = end
01328 end += 4
01329 (length,) = _struct_I.unpack(str[start:end])
01330 pattern = '<%sf'%length
01331 start = end
01332 end += struct.calcsize(pattern)
01333 val1.values = struct.unpack(pattern, str[start:end])
01334 self.action_goal.goal.options.selected_object.cluster.channels.append(val1)
01335 _x = self
01336 start = end
01337 end += 12
01338 (_x.action_goal.goal.options.selected_object.region.cloud.header.seq, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01339 start = end
01340 end += 4
01341 (length,) = _struct_I.unpack(str[start:end])
01342 start = end
01343 end += length
01344 if python3:
01345 self.action_goal.goal.options.selected_object.region.cloud.header.frame_id = str[start:end].decode('utf-8')
01346 else:
01347 self.action_goal.goal.options.selected_object.region.cloud.header.frame_id = str[start:end]
01348 _x = self
01349 start = end
01350 end += 8
01351 (_x.action_goal.goal.options.selected_object.region.cloud.height, _x.action_goal.goal.options.selected_object.region.cloud.width,) = _struct_2I.unpack(str[start:end])
01352 start = end
01353 end += 4
01354 (length,) = _struct_I.unpack(str[start:end])
01355 self.action_goal.goal.options.selected_object.region.cloud.fields = []
01356 for i in range(0, length):
01357 val1 = sensor_msgs.msg.PointField()
01358 start = end
01359 end += 4
01360 (length,) = _struct_I.unpack(str[start:end])
01361 start = end
01362 end += length
01363 if python3:
01364 val1.name = str[start:end].decode('utf-8')
01365 else:
01366 val1.name = str[start:end]
01367 _x = val1
01368 start = end
01369 end += 9
01370 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
01371 self.action_goal.goal.options.selected_object.region.cloud.fields.append(val1)
01372 _x = self
01373 start = end
01374 end += 9
01375 (_x.action_goal.goal.options.selected_object.region.cloud.is_bigendian, _x.action_goal.goal.options.selected_object.region.cloud.point_step, _x.action_goal.goal.options.selected_object.region.cloud.row_step,) = _struct_B2I.unpack(str[start:end])
01376 self.action_goal.goal.options.selected_object.region.cloud.is_bigendian = bool(self.action_goal.goal.options.selected_object.region.cloud.is_bigendian)
01377 start = end
01378 end += 4
01379 (length,) = _struct_I.unpack(str[start:end])
01380 start = end
01381 end += length
01382 if python3:
01383 self.action_goal.goal.options.selected_object.region.cloud.data = str[start:end].decode('utf-8')
01384 else:
01385 self.action_goal.goal.options.selected_object.region.cloud.data = str[start:end]
01386 start = end
01387 end += 1
01388 (self.action_goal.goal.options.selected_object.region.cloud.is_dense,) = _struct_B.unpack(str[start:end])
01389 self.action_goal.goal.options.selected_object.region.cloud.is_dense = bool(self.action_goal.goal.options.selected_object.region.cloud.is_dense)
01390 start = end
01391 end += 4
01392 (length,) = _struct_I.unpack(str[start:end])
01393 pattern = '<%si'%length
01394 start = end
01395 end += struct.calcsize(pattern)
01396 self.action_goal.goal.options.selected_object.region.mask = struct.unpack(pattern, str[start:end])
01397 _x = self
01398 start = end
01399 end += 12
01400 (_x.action_goal.goal.options.selected_object.region.image.header.seq, _x.action_goal.goal.options.selected_object.region.image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.image.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01401 start = end
01402 end += 4
01403 (length,) = _struct_I.unpack(str[start:end])
01404 start = end
01405 end += length
01406 if python3:
01407 self.action_goal.goal.options.selected_object.region.image.header.frame_id = str[start:end].decode('utf-8')
01408 else:
01409 self.action_goal.goal.options.selected_object.region.image.header.frame_id = str[start:end]
01410 _x = self
01411 start = end
01412 end += 8
01413 (_x.action_goal.goal.options.selected_object.region.image.height, _x.action_goal.goal.options.selected_object.region.image.width,) = _struct_2I.unpack(str[start:end])
01414 start = end
01415 end += 4
01416 (length,) = _struct_I.unpack(str[start:end])
01417 start = end
01418 end += length
01419 if python3:
01420 self.action_goal.goal.options.selected_object.region.image.encoding = str[start:end].decode('utf-8')
01421 else:
01422 self.action_goal.goal.options.selected_object.region.image.encoding = str[start:end]
01423 _x = self
01424 start = end
01425 end += 5
01426 (_x.action_goal.goal.options.selected_object.region.image.is_bigendian, _x.action_goal.goal.options.selected_object.region.image.step,) = _struct_BI.unpack(str[start:end])
01427 start = end
01428 end += 4
01429 (length,) = _struct_I.unpack(str[start:end])
01430 start = end
01431 end += length
01432 if python3:
01433 self.action_goal.goal.options.selected_object.region.image.data = str[start:end].decode('utf-8')
01434 else:
01435 self.action_goal.goal.options.selected_object.region.image.data = str[start:end]
01436 _x = self
01437 start = end
01438 end += 12
01439 (_x.action_goal.goal.options.selected_object.region.disparity_image.header.seq, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01440 start = end
01441 end += 4
01442 (length,) = _struct_I.unpack(str[start:end])
01443 start = end
01444 end += length
01445 if python3:
01446 self.action_goal.goal.options.selected_object.region.disparity_image.header.frame_id = str[start:end].decode('utf-8')
01447 else:
01448 self.action_goal.goal.options.selected_object.region.disparity_image.header.frame_id = str[start:end]
01449 _x = self
01450 start = end
01451 end += 8
01452 (_x.action_goal.goal.options.selected_object.region.disparity_image.height, _x.action_goal.goal.options.selected_object.region.disparity_image.width,) = _struct_2I.unpack(str[start:end])
01453 start = end
01454 end += 4
01455 (length,) = _struct_I.unpack(str[start:end])
01456 start = end
01457 end += length
01458 if python3:
01459 self.action_goal.goal.options.selected_object.region.disparity_image.encoding = str[start:end].decode('utf-8')
01460 else:
01461 self.action_goal.goal.options.selected_object.region.disparity_image.encoding = str[start:end]
01462 _x = self
01463 start = end
01464 end += 5
01465 (_x.action_goal.goal.options.selected_object.region.disparity_image.is_bigendian, _x.action_goal.goal.options.selected_object.region.disparity_image.step,) = _struct_BI.unpack(str[start:end])
01466 start = end
01467 end += 4
01468 (length,) = _struct_I.unpack(str[start:end])
01469 start = end
01470 end += length
01471 if python3:
01472 self.action_goal.goal.options.selected_object.region.disparity_image.data = str[start:end].decode('utf-8')
01473 else:
01474 self.action_goal.goal.options.selected_object.region.disparity_image.data = str[start:end]
01475 _x = self
01476 start = end
01477 end += 12
01478 (_x.action_goal.goal.options.selected_object.region.cam_info.header.seq, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01479 start = end
01480 end += 4
01481 (length,) = _struct_I.unpack(str[start:end])
01482 start = end
01483 end += length
01484 if python3:
01485 self.action_goal.goal.options.selected_object.region.cam_info.header.frame_id = str[start:end].decode('utf-8')
01486 else:
01487 self.action_goal.goal.options.selected_object.region.cam_info.header.frame_id = str[start:end]
01488 _x = self
01489 start = end
01490 end += 8
01491 (_x.action_goal.goal.options.selected_object.region.cam_info.height, _x.action_goal.goal.options.selected_object.region.cam_info.width,) = _struct_2I.unpack(str[start:end])
01492 start = end
01493 end += 4
01494 (length,) = _struct_I.unpack(str[start:end])
01495 start = end
01496 end += length
01497 if python3:
01498 self.action_goal.goal.options.selected_object.region.cam_info.distortion_model = str[start:end].decode('utf-8')
01499 else:
01500 self.action_goal.goal.options.selected_object.region.cam_info.distortion_model = str[start:end]
01501 start = end
01502 end += 4
01503 (length,) = _struct_I.unpack(str[start:end])
01504 pattern = '<%sd'%length
01505 start = end
01506 end += struct.calcsize(pattern)
01507 self.action_goal.goal.options.selected_object.region.cam_info.D = struct.unpack(pattern, str[start:end])
01508 start = end
01509 end += 72
01510 self.action_goal.goal.options.selected_object.region.cam_info.K = _struct_9d.unpack(str[start:end])
01511 start = end
01512 end += 72
01513 self.action_goal.goal.options.selected_object.region.cam_info.R = _struct_9d.unpack(str[start:end])
01514 start = end
01515 end += 96
01516 self.action_goal.goal.options.selected_object.region.cam_info.P = _struct_12d.unpack(str[start:end])
01517 _x = self
01518 start = end
01519 end += 37
01520 (_x.action_goal.goal.options.selected_object.region.cam_info.binning_x, _x.action_goal.goal.options.selected_object.region.cam_info.binning_y, _x.action_goal.goal.options.selected_object.region.cam_info.roi.x_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.y_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.height, _x.action_goal.goal.options.selected_object.region.cam_info.roi.width, _x.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.seq, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.nsecs,) = _struct_6IB3I.unpack(str[start:end])
01521 self.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify = bool(self.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify)
01522 start = end
01523 end += 4
01524 (length,) = _struct_I.unpack(str[start:end])
01525 start = end
01526 end += length
01527 if python3:
01528 self.action_goal.goal.options.selected_object.region.roi_box_pose.header.frame_id = str[start:end].decode('utf-8')
01529 else:
01530 self.action_goal.goal.options.selected_object.region.roi_box_pose.header.frame_id = str[start:end]
01531 _x = self
01532 start = end
01533 end += 80
01534 (_x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.w, _x.action_goal.goal.options.selected_object.region.roi_box_dims.x, _x.action_goal.goal.options.selected_object.region.roi_box_dims.y, _x.action_goal.goal.options.selected_object.region.roi_box_dims.z,) = _struct_10d.unpack(str[start:end])
01535 start = end
01536 end += 4
01537 (length,) = _struct_I.unpack(str[start:end])
01538 start = end
01539 end += length
01540 if python3:
01541 self.action_goal.goal.options.selected_object.collision_name = str[start:end].decode('utf-8')
01542 else:
01543 self.action_goal.goal.options.selected_object.collision_name = str[start:end]
01544 start = end
01545 end += 4
01546 (length,) = _struct_I.unpack(str[start:end])
01547 self.action_goal.goal.options.movable_obstacles = []
01548 for i in range(0, length):
01549 val1 = object_manipulation_msgs.msg.GraspableObject()
01550 start = end
01551 end += 4
01552 (length,) = _struct_I.unpack(str[start:end])
01553 start = end
01554 end += length
01555 if python3:
01556 val1.reference_frame_id = str[start:end].decode('utf-8')
01557 else:
01558 val1.reference_frame_id = str[start:end]
01559 start = end
01560 end += 4
01561 (length,) = _struct_I.unpack(str[start:end])
01562 val1.potential_models = []
01563 for i in range(0, length):
01564 val2 = household_objects_database_msgs.msg.DatabaseModelPose()
01565 start = end
01566 end += 4
01567 (val2.model_id,) = _struct_i.unpack(str[start:end])
01568 _v43 = val2.pose
01569 _v44 = _v43.header
01570 start = end
01571 end += 4
01572 (_v44.seq,) = _struct_I.unpack(str[start:end])
01573 _v45 = _v44.stamp
01574 _x = _v45
01575 start = end
01576 end += 8
01577 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01578 start = end
01579 end += 4
01580 (length,) = _struct_I.unpack(str[start:end])
01581 start = end
01582 end += length
01583 if python3:
01584 _v44.frame_id = str[start:end].decode('utf-8')
01585 else:
01586 _v44.frame_id = str[start:end]
01587 _v46 = _v43.pose
01588 _v47 = _v46.position
01589 _x = _v47
01590 start = end
01591 end += 24
01592 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
01593 _v48 = _v46.orientation
01594 _x = _v48
01595 start = end
01596 end += 32
01597 (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
01598 start = end
01599 end += 4
01600 (val2.confidence,) = _struct_f.unpack(str[start:end])
01601 start = end
01602 end += 4
01603 (length,) = _struct_I.unpack(str[start:end])
01604 start = end
01605 end += length
01606 if python3:
01607 val2.detector_name = str[start:end].decode('utf-8')
01608 else:
01609 val2.detector_name = str[start:end]
01610 val1.potential_models.append(val2)
01611 _v49 = val1.cluster
01612 _v50 = _v49.header
01613 start = end
01614 end += 4
01615 (_v50.seq,) = _struct_I.unpack(str[start:end])
01616 _v51 = _v50.stamp
01617 _x = _v51
01618 start = end
01619 end += 8
01620 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01621 start = end
01622 end += 4
01623 (length,) = _struct_I.unpack(str[start:end])
01624 start = end
01625 end += length
01626 if python3:
01627 _v50.frame_id = str[start:end].decode('utf-8')
01628 else:
01629 _v50.frame_id = str[start:end]
01630 start = end
01631 end += 4
01632 (length,) = _struct_I.unpack(str[start:end])
01633 _v49.points = []
01634 for i in range(0, length):
01635 val3 = geometry_msgs.msg.Point32()
01636 _x = val3
01637 start = end
01638 end += 12
01639 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
01640 _v49.points.append(val3)
01641 start = end
01642 end += 4
01643 (length,) = _struct_I.unpack(str[start:end])
01644 _v49.channels = []
01645 for i in range(0, length):
01646 val3 = sensor_msgs.msg.ChannelFloat32()
01647 start = end
01648 end += 4
01649 (length,) = _struct_I.unpack(str[start:end])
01650 start = end
01651 end += length
01652 if python3:
01653 val3.name = str[start:end].decode('utf-8')
01654 else:
01655 val3.name = str[start:end]
01656 start = end
01657 end += 4
01658 (length,) = _struct_I.unpack(str[start:end])
01659 pattern = '<%sf'%length
01660 start = end
01661 end += struct.calcsize(pattern)
01662 val3.values = struct.unpack(pattern, str[start:end])
01663 _v49.channels.append(val3)
01664 _v52 = val1.region
01665 _v53 = _v52.cloud
01666 _v54 = _v53.header
01667 start = end
01668 end += 4
01669 (_v54.seq,) = _struct_I.unpack(str[start:end])
01670 _v55 = _v54.stamp
01671 _x = _v55
01672 start = end
01673 end += 8
01674 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01675 start = end
01676 end += 4
01677 (length,) = _struct_I.unpack(str[start:end])
01678 start = end
01679 end += length
01680 if python3:
01681 _v54.frame_id = str[start:end].decode('utf-8')
01682 else:
01683 _v54.frame_id = str[start:end]
01684 _x = _v53
01685 start = end
01686 end += 8
01687 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
01688 start = end
01689 end += 4
01690 (length,) = _struct_I.unpack(str[start:end])
01691 _v53.fields = []
01692 for i in range(0, length):
01693 val4 = sensor_msgs.msg.PointField()
01694 start = end
01695 end += 4
01696 (length,) = _struct_I.unpack(str[start:end])
01697 start = end
01698 end += length
01699 if python3:
01700 val4.name = str[start:end].decode('utf-8')
01701 else:
01702 val4.name = str[start:end]
01703 _x = val4
01704 start = end
01705 end += 9
01706 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
01707 _v53.fields.append(val4)
01708 _x = _v53
01709 start = end
01710 end += 9
01711 (_x.is_bigendian, _x.point_step, _x.row_step,) = _struct_B2I.unpack(str[start:end])
01712 _v53.is_bigendian = bool(_v53.is_bigendian)
01713 start = end
01714 end += 4
01715 (length,) = _struct_I.unpack(str[start:end])
01716 start = end
01717 end += length
01718 if python3:
01719 _v53.data = str[start:end].decode('utf-8')
01720 else:
01721 _v53.data = str[start:end]
01722 start = end
01723 end += 1
01724 (_v53.is_dense,) = _struct_B.unpack(str[start:end])
01725 _v53.is_dense = bool(_v53.is_dense)
01726 start = end
01727 end += 4
01728 (length,) = _struct_I.unpack(str[start:end])
01729 pattern = '<%si'%length
01730 start = end
01731 end += struct.calcsize(pattern)
01732 _v52.mask = struct.unpack(pattern, str[start:end])
01733 _v56 = _v52.image
01734 _v57 = _v56.header
01735 start = end
01736 end += 4
01737 (_v57.seq,) = _struct_I.unpack(str[start:end])
01738 _v58 = _v57.stamp
01739 _x = _v58
01740 start = end
01741 end += 8
01742 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01743 start = end
01744 end += 4
01745 (length,) = _struct_I.unpack(str[start:end])
01746 start = end
01747 end += length
01748 if python3:
01749 _v57.frame_id = str[start:end].decode('utf-8')
01750 else:
01751 _v57.frame_id = str[start:end]
01752 _x = _v56
01753 start = end
01754 end += 8
01755 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
01756 start = end
01757 end += 4
01758 (length,) = _struct_I.unpack(str[start:end])
01759 start = end
01760 end += length
01761 if python3:
01762 _v56.encoding = str[start:end].decode('utf-8')
01763 else:
01764 _v56.encoding = str[start:end]
01765 _x = _v56
01766 start = end
01767 end += 5
01768 (_x.is_bigendian, _x.step,) = _struct_BI.unpack(str[start:end])
01769 start = end
01770 end += 4
01771 (length,) = _struct_I.unpack(str[start:end])
01772 start = end
01773 end += length
01774 if python3:
01775 _v56.data = str[start:end].decode('utf-8')
01776 else:
01777 _v56.data = str[start:end]
01778 _v59 = _v52.disparity_image
01779 _v60 = _v59.header
01780 start = end
01781 end += 4
01782 (_v60.seq,) = _struct_I.unpack(str[start:end])
01783 _v61 = _v60.stamp
01784 _x = _v61
01785 start = end
01786 end += 8
01787 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01788 start = end
01789 end += 4
01790 (length,) = _struct_I.unpack(str[start:end])
01791 start = end
01792 end += length
01793 if python3:
01794 _v60.frame_id = str[start:end].decode('utf-8')
01795 else:
01796 _v60.frame_id = str[start:end]
01797 _x = _v59
01798 start = end
01799 end += 8
01800 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
01801 start = end
01802 end += 4
01803 (length,) = _struct_I.unpack(str[start:end])
01804 start = end
01805 end += length
01806 if python3:
01807 _v59.encoding = str[start:end].decode('utf-8')
01808 else:
01809 _v59.encoding = str[start:end]
01810 _x = _v59
01811 start = end
01812 end += 5
01813 (_x.is_bigendian, _x.step,) = _struct_BI.unpack(str[start:end])
01814 start = end
01815 end += 4
01816 (length,) = _struct_I.unpack(str[start:end])
01817 start = end
01818 end += length
01819 if python3:
01820 _v59.data = str[start:end].decode('utf-8')
01821 else:
01822 _v59.data = str[start:end]
01823 _v62 = _v52.cam_info
01824 _v63 = _v62.header
01825 start = end
01826 end += 4
01827 (_v63.seq,) = _struct_I.unpack(str[start:end])
01828 _v64 = _v63.stamp
01829 _x = _v64
01830 start = end
01831 end += 8
01832 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01833 start = end
01834 end += 4
01835 (length,) = _struct_I.unpack(str[start:end])
01836 start = end
01837 end += length
01838 if python3:
01839 _v63.frame_id = str[start:end].decode('utf-8')
01840 else:
01841 _v63.frame_id = str[start:end]
01842 _x = _v62
01843 start = end
01844 end += 8
01845 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
01846 start = end
01847 end += 4
01848 (length,) = _struct_I.unpack(str[start:end])
01849 start = end
01850 end += length
01851 if python3:
01852 _v62.distortion_model = str[start:end].decode('utf-8')
01853 else:
01854 _v62.distortion_model = str[start:end]
01855 start = end
01856 end += 4
01857 (length,) = _struct_I.unpack(str[start:end])
01858 pattern = '<%sd'%length
01859 start = end
01860 end += struct.calcsize(pattern)
01861 _v62.D = struct.unpack(pattern, str[start:end])
01862 start = end
01863 end += 72
01864 _v62.K = _struct_9d.unpack(str[start:end])
01865 start = end
01866 end += 72
01867 _v62.R = _struct_9d.unpack(str[start:end])
01868 start = end
01869 end += 96
01870 _v62.P = _struct_12d.unpack(str[start:end])
01871 _x = _v62
01872 start = end
01873 end += 8
01874 (_x.binning_x, _x.binning_y,) = _struct_2I.unpack(str[start:end])
01875 _v65 = _v62.roi
01876 _x = _v65
01877 start = end
01878 end += 17
01879 (_x.x_offset, _x.y_offset, _x.height, _x.width, _x.do_rectify,) = _struct_4IB.unpack(str[start:end])
01880 _v65.do_rectify = bool(_v65.do_rectify)
01881 _v66 = _v52.roi_box_pose
01882 _v67 = _v66.header
01883 start = end
01884 end += 4
01885 (_v67.seq,) = _struct_I.unpack(str[start:end])
01886 _v68 = _v67.stamp
01887 _x = _v68
01888 start = end
01889 end += 8
01890 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
01891 start = end
01892 end += 4
01893 (length,) = _struct_I.unpack(str[start:end])
01894 start = end
01895 end += length
01896 if python3:
01897 _v67.frame_id = str[start:end].decode('utf-8')
01898 else:
01899 _v67.frame_id = str[start:end]
01900 _v69 = _v66.pose
01901 _v70 = _v69.position
01902 _x = _v70
01903 start = end
01904 end += 24
01905 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
01906 _v71 = _v69.orientation
01907 _x = _v71
01908 start = end
01909 end += 32
01910 (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
01911 _v72 = _v52.roi_box_dims
01912 _x = _v72
01913 start = end
01914 end += 24
01915 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
01916 start = end
01917 end += 4
01918 (length,) = _struct_I.unpack(str[start:end])
01919 start = end
01920 end += length
01921 if python3:
01922 val1.collision_name = str[start:end].decode('utf-8')
01923 else:
01924 val1.collision_name = str[start:end]
01925 self.action_goal.goal.options.movable_obstacles.append(val1)
01926 _x = self
01927 start = end
01928 end += 34
01929 (_x.action_goal.goal.options.adv_options.reactive_grasping, _x.action_goal.goal.options.adv_options.reactive_force, _x.action_goal.goal.options.adv_options.reactive_place, _x.action_goal.goal.options.adv_options.lift_steps, _x.action_goal.goal.options.adv_options.retreat_steps, _x.action_goal.goal.options.adv_options.lift_direction_choice, _x.action_goal.goal.options.adv_options.desired_approach, _x.action_goal.goal.options.adv_options.min_approach, _x.action_goal.goal.options.adv_options.max_contact_force, _x.action_goal.goal.options.adv_options.find_alternatives, _x.action_goal.goal.options.adv_options.always_plan_grasps, _x.action_goal.goal.options.adv_options.cycle_gripper_opening, _x.action_goal.goal.command.command,) = _struct_3B5if3Bi.unpack(str[start:end])
01930 self.action_goal.goal.options.adv_options.reactive_grasping = bool(self.action_goal.goal.options.adv_options.reactive_grasping)
01931 self.action_goal.goal.options.adv_options.reactive_force = bool(self.action_goal.goal.options.adv_options.reactive_force)
01932 self.action_goal.goal.options.adv_options.reactive_place = bool(self.action_goal.goal.options.adv_options.reactive_place)
01933 self.action_goal.goal.options.adv_options.find_alternatives = bool(self.action_goal.goal.options.adv_options.find_alternatives)
01934 self.action_goal.goal.options.adv_options.always_plan_grasps = bool(self.action_goal.goal.options.adv_options.always_plan_grasps)
01935 self.action_goal.goal.options.adv_options.cycle_gripper_opening = bool(self.action_goal.goal.options.adv_options.cycle_gripper_opening)
01936 start = end
01937 end += 4
01938 (length,) = _struct_I.unpack(str[start:end])
01939 start = end
01940 end += length
01941 if python3:
01942 self.action_goal.goal.command.script_name = str[start:end].decode('utf-8')
01943 else:
01944 self.action_goal.goal.command.script_name = str[start:end]
01945 start = end
01946 end += 4
01947 (length,) = _struct_I.unpack(str[start:end])
01948 start = end
01949 end += length
01950 if python3:
01951 self.action_goal.goal.command.script_group_name = str[start:end].decode('utf-8')
01952 else:
01953 self.action_goal.goal.command.script_group_name = str[start:end]
01954 _x = self
01955 start = end
01956 end += 12
01957 (_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
01958 start = end
01959 end += 4
01960 (length,) = _struct_I.unpack(str[start:end])
01961 start = end
01962 end += length
01963 if python3:
01964 self.action_result.header.frame_id = str[start:end].decode('utf-8')
01965 else:
01966 self.action_result.header.frame_id = str[start:end]
01967 _x = self
01968 start = end
01969 end += 8
01970 (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
01971 start = end
01972 end += 4
01973 (length,) = _struct_I.unpack(str[start:end])
01974 start = end
01975 end += length
01976 if python3:
01977 self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
01978 else:
01979 self.action_result.status.goal_id.id = str[start:end]
01980 start = end
01981 end += 1
01982 (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
01983 start = end
01984 end += 4
01985 (length,) = _struct_I.unpack(str[start:end])
01986 start = end
01987 end += length
01988 if python3:
01989 self.action_result.status.text = str[start:end].decode('utf-8')
01990 else:
01991 self.action_result.status.text = str[start:end]
01992 _x = self
01993 start = end
01994 end += 16
01995 (_x.action_result.result.result.value, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_i3I.unpack(str[start:end])
01996 start = end
01997 end += 4
01998 (length,) = _struct_I.unpack(str[start:end])
01999 start = end
02000 end += length
02001 if python3:
02002 self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
02003 else:
02004 self.action_feedback.header.frame_id = str[start:end]
02005 _x = self
02006 start = end
02007 end += 8
02008 (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
02009 start = end
02010 end += 4
02011 (length,) = _struct_I.unpack(str[start:end])
02012 start = end
02013 end += length
02014 if python3:
02015 self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
02016 else:
02017 self.action_feedback.status.goal_id.id = str[start:end]
02018 start = end
02019 end += 1
02020 (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
02021 start = end
02022 end += 4
02023 (length,) = _struct_I.unpack(str[start:end])
02024 start = end
02025 end += length
02026 if python3:
02027 self.action_feedback.status.text = str[start:end].decode('utf-8')
02028 else:
02029 self.action_feedback.status.text = str[start:end]
02030 start = end
02031 end += 4
02032 (length,) = _struct_I.unpack(str[start:end])
02033 start = end
02034 end += length
02035 if python3:
02036 self.action_feedback.feedback.status = str[start:end].decode('utf-8')
02037 else:
02038 self.action_feedback.feedback.status = str[start:end]
02039 return self
02040 except struct.error as e:
02041 raise genpy.DeserializationError(e) #most likely buffer underfill
02042
02043
02044 def serialize_numpy(self, buff, numpy):
02045 """
02046 serialize message with numpy array types into buffer
02047 :param buff: buffer, ``StringIO``
02048 :param numpy: numpy python module
02049 """
02050 try:
02051 _x = self
02052 buff.write(_struct_3I.pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
02053 _x = self.action_goal.header.frame_id
02054 length = len(_x)
02055 if python3 or type(_x) == unicode:
02056 _x = _x.encode('utf-8')
02057 length = len(_x)
02058 buff.write(struct.pack('<I%ss'%length, length, _x))
02059 _x = self
02060 buff.write(_struct_2I.pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
02061 _x = self.action_goal.goal_id.id
02062 length = len(_x)
02063 if python3 or type(_x) == unicode:
02064 _x = _x.encode('utf-8')
02065 length = len(_x)
02066 buff.write(struct.pack('<I%ss'%length, length, _x))
02067 _x = self
02068 buff.write(_struct_B6i.pack(_x.action_goal.goal.options.collision_checked, _x.action_goal.goal.options.grasp_selection, _x.action_goal.goal.options.arm_selection, _x.action_goal.goal.options.reset_choice, _x.action_goal.goal.options.arm_action_choice, _x.action_goal.goal.options.arm_planner_choice, _x.action_goal.goal.options.gripper_slider_position))
02069 _x = self.action_goal.goal.options.selected_object.reference_frame_id
02070 length = len(_x)
02071 if python3 or type(_x) == unicode:
02072 _x = _x.encode('utf-8')
02073 length = len(_x)
02074 buff.write(struct.pack('<I%ss'%length, length, _x))
02075 length = len(self.action_goal.goal.options.selected_object.potential_models)
02076 buff.write(_struct_I.pack(length))
02077 for val1 in self.action_goal.goal.options.selected_object.potential_models:
02078 buff.write(_struct_i.pack(val1.model_id))
02079 _v73 = val1.pose
02080 _v74 = _v73.header
02081 buff.write(_struct_I.pack(_v74.seq))
02082 _v75 = _v74.stamp
02083 _x = _v75
02084 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02085 _x = _v74.frame_id
02086 length = len(_x)
02087 if python3 or type(_x) == unicode:
02088 _x = _x.encode('utf-8')
02089 length = len(_x)
02090 buff.write(struct.pack('<I%ss'%length, length, _x))
02091 _v76 = _v73.pose
02092 _v77 = _v76.position
02093 _x = _v77
02094 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
02095 _v78 = _v76.orientation
02096 _x = _v78
02097 buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
02098 buff.write(_struct_f.pack(val1.confidence))
02099 _x = val1.detector_name
02100 length = len(_x)
02101 if python3 or type(_x) == unicode:
02102 _x = _x.encode('utf-8')
02103 length = len(_x)
02104 buff.write(struct.pack('<I%ss'%length, length, _x))
02105 _x = self
02106 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.cluster.header.seq, _x.action_goal.goal.options.selected_object.cluster.header.stamp.secs, _x.action_goal.goal.options.selected_object.cluster.header.stamp.nsecs))
02107 _x = self.action_goal.goal.options.selected_object.cluster.header.frame_id
02108 length = len(_x)
02109 if python3 or type(_x) == unicode:
02110 _x = _x.encode('utf-8')
02111 length = len(_x)
02112 buff.write(struct.pack('<I%ss'%length, length, _x))
02113 length = len(self.action_goal.goal.options.selected_object.cluster.points)
02114 buff.write(_struct_I.pack(length))
02115 for val1 in self.action_goal.goal.options.selected_object.cluster.points:
02116 _x = val1
02117 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
02118 length = len(self.action_goal.goal.options.selected_object.cluster.channels)
02119 buff.write(_struct_I.pack(length))
02120 for val1 in self.action_goal.goal.options.selected_object.cluster.channels:
02121 _x = val1.name
02122 length = len(_x)
02123 if python3 or type(_x) == unicode:
02124 _x = _x.encode('utf-8')
02125 length = len(_x)
02126 buff.write(struct.pack('<I%ss'%length, length, _x))
02127 length = len(val1.values)
02128 buff.write(_struct_I.pack(length))
02129 pattern = '<%sf'%length
02130 buff.write(val1.values.tostring())
02131 _x = self
02132 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.cloud.header.seq, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.nsecs))
02133 _x = self.action_goal.goal.options.selected_object.region.cloud.header.frame_id
02134 length = len(_x)
02135 if python3 or type(_x) == unicode:
02136 _x = _x.encode('utf-8')
02137 length = len(_x)
02138 buff.write(struct.pack('<I%ss'%length, length, _x))
02139 _x = self
02140 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.cloud.height, _x.action_goal.goal.options.selected_object.region.cloud.width))
02141 length = len(self.action_goal.goal.options.selected_object.region.cloud.fields)
02142 buff.write(_struct_I.pack(length))
02143 for val1 in self.action_goal.goal.options.selected_object.region.cloud.fields:
02144 _x = val1.name
02145 length = len(_x)
02146 if python3 or type(_x) == unicode:
02147 _x = _x.encode('utf-8')
02148 length = len(_x)
02149 buff.write(struct.pack('<I%ss'%length, length, _x))
02150 _x = val1
02151 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
02152 _x = self
02153 buff.write(_struct_B2I.pack(_x.action_goal.goal.options.selected_object.region.cloud.is_bigendian, _x.action_goal.goal.options.selected_object.region.cloud.point_step, _x.action_goal.goal.options.selected_object.region.cloud.row_step))
02154 _x = self.action_goal.goal.options.selected_object.region.cloud.data
02155 length = len(_x)
02156 # - if encoded as a list instead, serialize as bytes instead of string
02157 if type(_x) in [list, tuple]:
02158 buff.write(struct.pack('<I%sB'%length, length, *_x))
02159 else:
02160 buff.write(struct.pack('<I%ss'%length, length, _x))
02161 buff.write(_struct_B.pack(self.action_goal.goal.options.selected_object.region.cloud.is_dense))
02162 length = len(self.action_goal.goal.options.selected_object.region.mask)
02163 buff.write(_struct_I.pack(length))
02164 pattern = '<%si'%length
02165 buff.write(self.action_goal.goal.options.selected_object.region.mask.tostring())
02166 _x = self
02167 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.image.header.seq, _x.action_goal.goal.options.selected_object.region.image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.image.header.stamp.nsecs))
02168 _x = self.action_goal.goal.options.selected_object.region.image.header.frame_id
02169 length = len(_x)
02170 if python3 or type(_x) == unicode:
02171 _x = _x.encode('utf-8')
02172 length = len(_x)
02173 buff.write(struct.pack('<I%ss'%length, length, _x))
02174 _x = self
02175 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.image.height, _x.action_goal.goal.options.selected_object.region.image.width))
02176 _x = self.action_goal.goal.options.selected_object.region.image.encoding
02177 length = len(_x)
02178 if python3 or type(_x) == unicode:
02179 _x = _x.encode('utf-8')
02180 length = len(_x)
02181 buff.write(struct.pack('<I%ss'%length, length, _x))
02182 _x = self
02183 buff.write(_struct_BI.pack(_x.action_goal.goal.options.selected_object.region.image.is_bigendian, _x.action_goal.goal.options.selected_object.region.image.step))
02184 _x = self.action_goal.goal.options.selected_object.region.image.data
02185 length = len(_x)
02186 # - if encoded as a list instead, serialize as bytes instead of string
02187 if type(_x) in [list, tuple]:
02188 buff.write(struct.pack('<I%sB'%length, length, *_x))
02189 else:
02190 buff.write(struct.pack('<I%ss'%length, length, _x))
02191 _x = self
02192 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.disparity_image.header.seq, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.nsecs))
02193 _x = self.action_goal.goal.options.selected_object.region.disparity_image.header.frame_id
02194 length = len(_x)
02195 if python3 or type(_x) == unicode:
02196 _x = _x.encode('utf-8')
02197 length = len(_x)
02198 buff.write(struct.pack('<I%ss'%length, length, _x))
02199 _x = self
02200 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.disparity_image.height, _x.action_goal.goal.options.selected_object.region.disparity_image.width))
02201 _x = self.action_goal.goal.options.selected_object.region.disparity_image.encoding
02202 length = len(_x)
02203 if python3 or type(_x) == unicode:
02204 _x = _x.encode('utf-8')
02205 length = len(_x)
02206 buff.write(struct.pack('<I%ss'%length, length, _x))
02207 _x = self
02208 buff.write(_struct_BI.pack(_x.action_goal.goal.options.selected_object.region.disparity_image.is_bigendian, _x.action_goal.goal.options.selected_object.region.disparity_image.step))
02209 _x = self.action_goal.goal.options.selected_object.region.disparity_image.data
02210 length = len(_x)
02211 # - if encoded as a list instead, serialize as bytes instead of string
02212 if type(_x) in [list, tuple]:
02213 buff.write(struct.pack('<I%sB'%length, length, *_x))
02214 else:
02215 buff.write(struct.pack('<I%ss'%length, length, _x))
02216 _x = self
02217 buff.write(_struct_3I.pack(_x.action_goal.goal.options.selected_object.region.cam_info.header.seq, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.nsecs))
02218 _x = self.action_goal.goal.options.selected_object.region.cam_info.header.frame_id
02219 length = len(_x)
02220 if python3 or type(_x) == unicode:
02221 _x = _x.encode('utf-8')
02222 length = len(_x)
02223 buff.write(struct.pack('<I%ss'%length, length, _x))
02224 _x = self
02225 buff.write(_struct_2I.pack(_x.action_goal.goal.options.selected_object.region.cam_info.height, _x.action_goal.goal.options.selected_object.region.cam_info.width))
02226 _x = self.action_goal.goal.options.selected_object.region.cam_info.distortion_model
02227 length = len(_x)
02228 if python3 or type(_x) == unicode:
02229 _x = _x.encode('utf-8')
02230 length = len(_x)
02231 buff.write(struct.pack('<I%ss'%length, length, _x))
02232 length = len(self.action_goal.goal.options.selected_object.region.cam_info.D)
02233 buff.write(_struct_I.pack(length))
02234 pattern = '<%sd'%length
02235 buff.write(self.action_goal.goal.options.selected_object.region.cam_info.D.tostring())
02236 buff.write(self.action_goal.goal.options.selected_object.region.cam_info.K.tostring())
02237 buff.write(self.action_goal.goal.options.selected_object.region.cam_info.R.tostring())
02238 buff.write(self.action_goal.goal.options.selected_object.region.cam_info.P.tostring())
02239 _x = self
02240 buff.write(_struct_6IB3I.pack(_x.action_goal.goal.options.selected_object.region.cam_info.binning_x, _x.action_goal.goal.options.selected_object.region.cam_info.binning_y, _x.action_goal.goal.options.selected_object.region.cam_info.roi.x_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.y_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.height, _x.action_goal.goal.options.selected_object.region.cam_info.roi.width, _x.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.seq, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.nsecs))
02241 _x = self.action_goal.goal.options.selected_object.region.roi_box_pose.header.frame_id
02242 length = len(_x)
02243 if python3 or type(_x) == unicode:
02244 _x = _x.encode('utf-8')
02245 length = len(_x)
02246 buff.write(struct.pack('<I%ss'%length, length, _x))
02247 _x = self
02248 buff.write(_struct_10d.pack(_x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.w, _x.action_goal.goal.options.selected_object.region.roi_box_dims.x, _x.action_goal.goal.options.selected_object.region.roi_box_dims.y, _x.action_goal.goal.options.selected_object.region.roi_box_dims.z))
02249 _x = self.action_goal.goal.options.selected_object.collision_name
02250 length = len(_x)
02251 if python3 or type(_x) == unicode:
02252 _x = _x.encode('utf-8')
02253 length = len(_x)
02254 buff.write(struct.pack('<I%ss'%length, length, _x))
02255 length = len(self.action_goal.goal.options.movable_obstacles)
02256 buff.write(_struct_I.pack(length))
02257 for val1 in self.action_goal.goal.options.movable_obstacles:
02258 _x = val1.reference_frame_id
02259 length = len(_x)
02260 if python3 or type(_x) == unicode:
02261 _x = _x.encode('utf-8')
02262 length = len(_x)
02263 buff.write(struct.pack('<I%ss'%length, length, _x))
02264 length = len(val1.potential_models)
02265 buff.write(_struct_I.pack(length))
02266 for val2 in val1.potential_models:
02267 buff.write(_struct_i.pack(val2.model_id))
02268 _v79 = val2.pose
02269 _v80 = _v79.header
02270 buff.write(_struct_I.pack(_v80.seq))
02271 _v81 = _v80.stamp
02272 _x = _v81
02273 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02274 _x = _v80.frame_id
02275 length = len(_x)
02276 if python3 or type(_x) == unicode:
02277 _x = _x.encode('utf-8')
02278 length = len(_x)
02279 buff.write(struct.pack('<I%ss'%length, length, _x))
02280 _v82 = _v79.pose
02281 _v83 = _v82.position
02282 _x = _v83
02283 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
02284 _v84 = _v82.orientation
02285 _x = _v84
02286 buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
02287 buff.write(_struct_f.pack(val2.confidence))
02288 _x = val2.detector_name
02289 length = len(_x)
02290 if python3 or type(_x) == unicode:
02291 _x = _x.encode('utf-8')
02292 length = len(_x)
02293 buff.write(struct.pack('<I%ss'%length, length, _x))
02294 _v85 = val1.cluster
02295 _v86 = _v85.header
02296 buff.write(_struct_I.pack(_v86.seq))
02297 _v87 = _v86.stamp
02298 _x = _v87
02299 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02300 _x = _v86.frame_id
02301 length = len(_x)
02302 if python3 or type(_x) == unicode:
02303 _x = _x.encode('utf-8')
02304 length = len(_x)
02305 buff.write(struct.pack('<I%ss'%length, length, _x))
02306 length = len(_v85.points)
02307 buff.write(_struct_I.pack(length))
02308 for val3 in _v85.points:
02309 _x = val3
02310 buff.write(_struct_3f.pack(_x.x, _x.y, _x.z))
02311 length = len(_v85.channels)
02312 buff.write(_struct_I.pack(length))
02313 for val3 in _v85.channels:
02314 _x = val3.name
02315 length = len(_x)
02316 if python3 or type(_x) == unicode:
02317 _x = _x.encode('utf-8')
02318 length = len(_x)
02319 buff.write(struct.pack('<I%ss'%length, length, _x))
02320 length = len(val3.values)
02321 buff.write(_struct_I.pack(length))
02322 pattern = '<%sf'%length
02323 buff.write(val3.values.tostring())
02324 _v88 = val1.region
02325 _v89 = _v88.cloud
02326 _v90 = _v89.header
02327 buff.write(_struct_I.pack(_v90.seq))
02328 _v91 = _v90.stamp
02329 _x = _v91
02330 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02331 _x = _v90.frame_id
02332 length = len(_x)
02333 if python3 or type(_x) == unicode:
02334 _x = _x.encode('utf-8')
02335 length = len(_x)
02336 buff.write(struct.pack('<I%ss'%length, length, _x))
02337 _x = _v89
02338 buff.write(_struct_2I.pack(_x.height, _x.width))
02339 length = len(_v89.fields)
02340 buff.write(_struct_I.pack(length))
02341 for val4 in _v89.fields:
02342 _x = val4.name
02343 length = len(_x)
02344 if python3 or type(_x) == unicode:
02345 _x = _x.encode('utf-8')
02346 length = len(_x)
02347 buff.write(struct.pack('<I%ss'%length, length, _x))
02348 _x = val4
02349 buff.write(_struct_IBI.pack(_x.offset, _x.datatype, _x.count))
02350 _x = _v89
02351 buff.write(_struct_B2I.pack(_x.is_bigendian, _x.point_step, _x.row_step))
02352 _x = _v89.data
02353 length = len(_x)
02354 # - if encoded as a list instead, serialize as bytes instead of string
02355 if type(_x) in [list, tuple]:
02356 buff.write(struct.pack('<I%sB'%length, length, *_x))
02357 else:
02358 buff.write(struct.pack('<I%ss'%length, length, _x))
02359 buff.write(_struct_B.pack(_v89.is_dense))
02360 length = len(_v88.mask)
02361 buff.write(_struct_I.pack(length))
02362 pattern = '<%si'%length
02363 buff.write(_v88.mask.tostring())
02364 _v92 = _v88.image
02365 _v93 = _v92.header
02366 buff.write(_struct_I.pack(_v93.seq))
02367 _v94 = _v93.stamp
02368 _x = _v94
02369 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02370 _x = _v93.frame_id
02371 length = len(_x)
02372 if python3 or type(_x) == unicode:
02373 _x = _x.encode('utf-8')
02374 length = len(_x)
02375 buff.write(struct.pack('<I%ss'%length, length, _x))
02376 _x = _v92
02377 buff.write(_struct_2I.pack(_x.height, _x.width))
02378 _x = _v92.encoding
02379 length = len(_x)
02380 if python3 or type(_x) == unicode:
02381 _x = _x.encode('utf-8')
02382 length = len(_x)
02383 buff.write(struct.pack('<I%ss'%length, length, _x))
02384 _x = _v92
02385 buff.write(_struct_BI.pack(_x.is_bigendian, _x.step))
02386 _x = _v92.data
02387 length = len(_x)
02388 # - if encoded as a list instead, serialize as bytes instead of string
02389 if type(_x) in [list, tuple]:
02390 buff.write(struct.pack('<I%sB'%length, length, *_x))
02391 else:
02392 buff.write(struct.pack('<I%ss'%length, length, _x))
02393 _v95 = _v88.disparity_image
02394 _v96 = _v95.header
02395 buff.write(_struct_I.pack(_v96.seq))
02396 _v97 = _v96.stamp
02397 _x = _v97
02398 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02399 _x = _v96.frame_id
02400 length = len(_x)
02401 if python3 or type(_x) == unicode:
02402 _x = _x.encode('utf-8')
02403 length = len(_x)
02404 buff.write(struct.pack('<I%ss'%length, length, _x))
02405 _x = _v95
02406 buff.write(_struct_2I.pack(_x.height, _x.width))
02407 _x = _v95.encoding
02408 length = len(_x)
02409 if python3 or type(_x) == unicode:
02410 _x = _x.encode('utf-8')
02411 length = len(_x)
02412 buff.write(struct.pack('<I%ss'%length, length, _x))
02413 _x = _v95
02414 buff.write(_struct_BI.pack(_x.is_bigendian, _x.step))
02415 _x = _v95.data
02416 length = len(_x)
02417 # - if encoded as a list instead, serialize as bytes instead of string
02418 if type(_x) in [list, tuple]:
02419 buff.write(struct.pack('<I%sB'%length, length, *_x))
02420 else:
02421 buff.write(struct.pack('<I%ss'%length, length, _x))
02422 _v98 = _v88.cam_info
02423 _v99 = _v98.header
02424 buff.write(_struct_I.pack(_v99.seq))
02425 _v100 = _v99.stamp
02426 _x = _v100
02427 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02428 _x = _v99.frame_id
02429 length = len(_x)
02430 if python3 or type(_x) == unicode:
02431 _x = _x.encode('utf-8')
02432 length = len(_x)
02433 buff.write(struct.pack('<I%ss'%length, length, _x))
02434 _x = _v98
02435 buff.write(_struct_2I.pack(_x.height, _x.width))
02436 _x = _v98.distortion_model
02437 length = len(_x)
02438 if python3 or type(_x) == unicode:
02439 _x = _x.encode('utf-8')
02440 length = len(_x)
02441 buff.write(struct.pack('<I%ss'%length, length, _x))
02442 length = len(_v98.D)
02443 buff.write(_struct_I.pack(length))
02444 pattern = '<%sd'%length
02445 buff.write(_v98.D.tostring())
02446 buff.write(_v98.K.tostring())
02447 buff.write(_v98.R.tostring())
02448 buff.write(_v98.P.tostring())
02449 _x = _v98
02450 buff.write(_struct_2I.pack(_x.binning_x, _x.binning_y))
02451 _v101 = _v98.roi
02452 _x = _v101
02453 buff.write(_struct_4IB.pack(_x.x_offset, _x.y_offset, _x.height, _x.width, _x.do_rectify))
02454 _v102 = _v88.roi_box_pose
02455 _v103 = _v102.header
02456 buff.write(_struct_I.pack(_v103.seq))
02457 _v104 = _v103.stamp
02458 _x = _v104
02459 buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
02460 _x = _v103.frame_id
02461 length = len(_x)
02462 if python3 or type(_x) == unicode:
02463 _x = _x.encode('utf-8')
02464 length = len(_x)
02465 buff.write(struct.pack('<I%ss'%length, length, _x))
02466 _v105 = _v102.pose
02467 _v106 = _v105.position
02468 _x = _v106
02469 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
02470 _v107 = _v105.orientation
02471 _x = _v107
02472 buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
02473 _v108 = _v88.roi_box_dims
02474 _x = _v108
02475 buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
02476 _x = val1.collision_name
02477 length = len(_x)
02478 if python3 or type(_x) == unicode:
02479 _x = _x.encode('utf-8')
02480 length = len(_x)
02481 buff.write(struct.pack('<I%ss'%length, length, _x))
02482 _x = self
02483 buff.write(_struct_3B5if3Bi.pack(_x.action_goal.goal.options.adv_options.reactive_grasping, _x.action_goal.goal.options.adv_options.reactive_force, _x.action_goal.goal.options.adv_options.reactive_place, _x.action_goal.goal.options.adv_options.lift_steps, _x.action_goal.goal.options.adv_options.retreat_steps, _x.action_goal.goal.options.adv_options.lift_direction_choice, _x.action_goal.goal.options.adv_options.desired_approach, _x.action_goal.goal.options.adv_options.min_approach, _x.action_goal.goal.options.adv_options.max_contact_force, _x.action_goal.goal.options.adv_options.find_alternatives, _x.action_goal.goal.options.adv_options.always_plan_grasps, _x.action_goal.goal.options.adv_options.cycle_gripper_opening, _x.action_goal.goal.command.command))
02484 _x = self.action_goal.goal.command.script_name
02485 length = len(_x)
02486 if python3 or type(_x) == unicode:
02487 _x = _x.encode('utf-8')
02488 length = len(_x)
02489 buff.write(struct.pack('<I%ss'%length, length, _x))
02490 _x = self.action_goal.goal.command.script_group_name
02491 length = len(_x)
02492 if python3 or type(_x) == unicode:
02493 _x = _x.encode('utf-8')
02494 length = len(_x)
02495 buff.write(struct.pack('<I%ss'%length, length, _x))
02496 _x = self
02497 buff.write(_struct_3I.pack(_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
02498 _x = self.action_result.header.frame_id
02499 length = len(_x)
02500 if python3 or type(_x) == unicode:
02501 _x = _x.encode('utf-8')
02502 length = len(_x)
02503 buff.write(struct.pack('<I%ss'%length, length, _x))
02504 _x = self
02505 buff.write(_struct_2I.pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
02506 _x = self.action_result.status.goal_id.id
02507 length = len(_x)
02508 if python3 or type(_x) == unicode:
02509 _x = _x.encode('utf-8')
02510 length = len(_x)
02511 buff.write(struct.pack('<I%ss'%length, length, _x))
02512 buff.write(_struct_B.pack(self.action_result.status.status))
02513 _x = self.action_result.status.text
02514 length = len(_x)
02515 if python3 or type(_x) == unicode:
02516 _x = _x.encode('utf-8')
02517 length = len(_x)
02518 buff.write(struct.pack('<I%ss'%length, length, _x))
02519 _x = self
02520 buff.write(_struct_i3I.pack(_x.action_result.result.result.value, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
02521 _x = self.action_feedback.header.frame_id
02522 length = len(_x)
02523 if python3 or type(_x) == unicode:
02524 _x = _x.encode('utf-8')
02525 length = len(_x)
02526 buff.write(struct.pack('<I%ss'%length, length, _x))
02527 _x = self
02528 buff.write(_struct_2I.pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
02529 _x = self.action_feedback.status.goal_id.id
02530 length = len(_x)
02531 if python3 or type(_x) == unicode:
02532 _x = _x.encode('utf-8')
02533 length = len(_x)
02534 buff.write(struct.pack('<I%ss'%length, length, _x))
02535 buff.write(_struct_B.pack(self.action_feedback.status.status))
02536 _x = self.action_feedback.status.text
02537 length = len(_x)
02538 if python3 or type(_x) == unicode:
02539 _x = _x.encode('utf-8')
02540 length = len(_x)
02541 buff.write(struct.pack('<I%ss'%length, length, _x))
02542 _x = self.action_feedback.feedback.status
02543 length = len(_x)
02544 if python3 or type(_x) == unicode:
02545 _x = _x.encode('utf-8')
02546 length = len(_x)
02547 buff.write(struct.pack('<I%ss'%length, length, _x))
02548 except struct.error as se: self._check_types(se)
02549 except TypeError as te: self._check_types(te)
02550
02551 def deserialize_numpy(self, str, numpy):
02552 """
02553 unpack serialized message in str into this message instance using numpy for array types
02554 :param str: byte array of serialized message, ``str``
02555 :param numpy: numpy python module
02556 """
02557 try:
02558 if self.action_goal is None:
02559 self.action_goal = pr2_object_manipulation_msgs.msg.IMGUIActionGoal()
02560 if self.action_result is None:
02561 self.action_result = pr2_object_manipulation_msgs.msg.IMGUIActionResult()
02562 if self.action_feedback is None:
02563 self.action_feedback = pr2_object_manipulation_msgs.msg.IMGUIActionFeedback()
02564 end = 0
02565 _x = self
02566 start = end
02567 end += 12
02568 (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
02569 start = end
02570 end += 4
02571 (length,) = _struct_I.unpack(str[start:end])
02572 start = end
02573 end += length
02574 if python3:
02575 self.action_goal.header.frame_id = str[start:end].decode('utf-8')
02576 else:
02577 self.action_goal.header.frame_id = str[start:end]
02578 _x = self
02579 start = end
02580 end += 8
02581 (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
02582 start = end
02583 end += 4
02584 (length,) = _struct_I.unpack(str[start:end])
02585 start = end
02586 end += length
02587 if python3:
02588 self.action_goal.goal_id.id = str[start:end].decode('utf-8')
02589 else:
02590 self.action_goal.goal_id.id = str[start:end]
02591 _x = self
02592 start = end
02593 end += 25
02594 (_x.action_goal.goal.options.collision_checked, _x.action_goal.goal.options.grasp_selection, _x.action_goal.goal.options.arm_selection, _x.action_goal.goal.options.reset_choice, _x.action_goal.goal.options.arm_action_choice, _x.action_goal.goal.options.arm_planner_choice, _x.action_goal.goal.options.gripper_slider_position,) = _struct_B6i.unpack(str[start:end])
02595 self.action_goal.goal.options.collision_checked = bool(self.action_goal.goal.options.collision_checked)
02596 start = end
02597 end += 4
02598 (length,) = _struct_I.unpack(str[start:end])
02599 start = end
02600 end += length
02601 if python3:
02602 self.action_goal.goal.options.selected_object.reference_frame_id = str[start:end].decode('utf-8')
02603 else:
02604 self.action_goal.goal.options.selected_object.reference_frame_id = str[start:end]
02605 start = end
02606 end += 4
02607 (length,) = _struct_I.unpack(str[start:end])
02608 self.action_goal.goal.options.selected_object.potential_models = []
02609 for i in range(0, length):
02610 val1 = household_objects_database_msgs.msg.DatabaseModelPose()
02611 start = end
02612 end += 4
02613 (val1.model_id,) = _struct_i.unpack(str[start:end])
02614 _v109 = val1.pose
02615 _v110 = _v109.header
02616 start = end
02617 end += 4
02618 (_v110.seq,) = _struct_I.unpack(str[start:end])
02619 _v111 = _v110.stamp
02620 _x = _v111
02621 start = end
02622 end += 8
02623 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
02624 start = end
02625 end += 4
02626 (length,) = _struct_I.unpack(str[start:end])
02627 start = end
02628 end += length
02629 if python3:
02630 _v110.frame_id = str[start:end].decode('utf-8')
02631 else:
02632 _v110.frame_id = str[start:end]
02633 _v112 = _v109.pose
02634 _v113 = _v112.position
02635 _x = _v113
02636 start = end
02637 end += 24
02638 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
02639 _v114 = _v112.orientation
02640 _x = _v114
02641 start = end
02642 end += 32
02643 (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
02644 start = end
02645 end += 4
02646 (val1.confidence,) = _struct_f.unpack(str[start:end])
02647 start = end
02648 end += 4
02649 (length,) = _struct_I.unpack(str[start:end])
02650 start = end
02651 end += length
02652 if python3:
02653 val1.detector_name = str[start:end].decode('utf-8')
02654 else:
02655 val1.detector_name = str[start:end]
02656 self.action_goal.goal.options.selected_object.potential_models.append(val1)
02657 _x = self
02658 start = end
02659 end += 12
02660 (_x.action_goal.goal.options.selected_object.cluster.header.seq, _x.action_goal.goal.options.selected_object.cluster.header.stamp.secs, _x.action_goal.goal.options.selected_object.cluster.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
02661 start = end
02662 end += 4
02663 (length,) = _struct_I.unpack(str[start:end])
02664 start = end
02665 end += length
02666 if python3:
02667 self.action_goal.goal.options.selected_object.cluster.header.frame_id = str[start:end].decode('utf-8')
02668 else:
02669 self.action_goal.goal.options.selected_object.cluster.header.frame_id = str[start:end]
02670 start = end
02671 end += 4
02672 (length,) = _struct_I.unpack(str[start:end])
02673 self.action_goal.goal.options.selected_object.cluster.points = []
02674 for i in range(0, length):
02675 val1 = geometry_msgs.msg.Point32()
02676 _x = val1
02677 start = end
02678 end += 12
02679 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
02680 self.action_goal.goal.options.selected_object.cluster.points.append(val1)
02681 start = end
02682 end += 4
02683 (length,) = _struct_I.unpack(str[start:end])
02684 self.action_goal.goal.options.selected_object.cluster.channels = []
02685 for i in range(0, length):
02686 val1 = sensor_msgs.msg.ChannelFloat32()
02687 start = end
02688 end += 4
02689 (length,) = _struct_I.unpack(str[start:end])
02690 start = end
02691 end += length
02692 if python3:
02693 val1.name = str[start:end].decode('utf-8')
02694 else:
02695 val1.name = str[start:end]
02696 start = end
02697 end += 4
02698 (length,) = _struct_I.unpack(str[start:end])
02699 pattern = '<%sf'%length
02700 start = end
02701 end += struct.calcsize(pattern)
02702 val1.values = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=length)
02703 self.action_goal.goal.options.selected_object.cluster.channels.append(val1)
02704 _x = self
02705 start = end
02706 end += 12
02707 (_x.action_goal.goal.options.selected_object.region.cloud.header.seq, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cloud.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
02708 start = end
02709 end += 4
02710 (length,) = _struct_I.unpack(str[start:end])
02711 start = end
02712 end += length
02713 if python3:
02714 self.action_goal.goal.options.selected_object.region.cloud.header.frame_id = str[start:end].decode('utf-8')
02715 else:
02716 self.action_goal.goal.options.selected_object.region.cloud.header.frame_id = str[start:end]
02717 _x = self
02718 start = end
02719 end += 8
02720 (_x.action_goal.goal.options.selected_object.region.cloud.height, _x.action_goal.goal.options.selected_object.region.cloud.width,) = _struct_2I.unpack(str[start:end])
02721 start = end
02722 end += 4
02723 (length,) = _struct_I.unpack(str[start:end])
02724 self.action_goal.goal.options.selected_object.region.cloud.fields = []
02725 for i in range(0, length):
02726 val1 = sensor_msgs.msg.PointField()
02727 start = end
02728 end += 4
02729 (length,) = _struct_I.unpack(str[start:end])
02730 start = end
02731 end += length
02732 if python3:
02733 val1.name = str[start:end].decode('utf-8')
02734 else:
02735 val1.name = str[start:end]
02736 _x = val1
02737 start = end
02738 end += 9
02739 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
02740 self.action_goal.goal.options.selected_object.region.cloud.fields.append(val1)
02741 _x = self
02742 start = end
02743 end += 9
02744 (_x.action_goal.goal.options.selected_object.region.cloud.is_bigendian, _x.action_goal.goal.options.selected_object.region.cloud.point_step, _x.action_goal.goal.options.selected_object.region.cloud.row_step,) = _struct_B2I.unpack(str[start:end])
02745 self.action_goal.goal.options.selected_object.region.cloud.is_bigendian = bool(self.action_goal.goal.options.selected_object.region.cloud.is_bigendian)
02746 start = end
02747 end += 4
02748 (length,) = _struct_I.unpack(str[start:end])
02749 start = end
02750 end += length
02751 if python3:
02752 self.action_goal.goal.options.selected_object.region.cloud.data = str[start:end].decode('utf-8')
02753 else:
02754 self.action_goal.goal.options.selected_object.region.cloud.data = str[start:end]
02755 start = end
02756 end += 1
02757 (self.action_goal.goal.options.selected_object.region.cloud.is_dense,) = _struct_B.unpack(str[start:end])
02758 self.action_goal.goal.options.selected_object.region.cloud.is_dense = bool(self.action_goal.goal.options.selected_object.region.cloud.is_dense)
02759 start = end
02760 end += 4
02761 (length,) = _struct_I.unpack(str[start:end])
02762 pattern = '<%si'%length
02763 start = end
02764 end += struct.calcsize(pattern)
02765 self.action_goal.goal.options.selected_object.region.mask = numpy.frombuffer(str[start:end], dtype=numpy.int32, count=length)
02766 _x = self
02767 start = end
02768 end += 12
02769 (_x.action_goal.goal.options.selected_object.region.image.header.seq, _x.action_goal.goal.options.selected_object.region.image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.image.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
02770 start = end
02771 end += 4
02772 (length,) = _struct_I.unpack(str[start:end])
02773 start = end
02774 end += length
02775 if python3:
02776 self.action_goal.goal.options.selected_object.region.image.header.frame_id = str[start:end].decode('utf-8')
02777 else:
02778 self.action_goal.goal.options.selected_object.region.image.header.frame_id = str[start:end]
02779 _x = self
02780 start = end
02781 end += 8
02782 (_x.action_goal.goal.options.selected_object.region.image.height, _x.action_goal.goal.options.selected_object.region.image.width,) = _struct_2I.unpack(str[start:end])
02783 start = end
02784 end += 4
02785 (length,) = _struct_I.unpack(str[start:end])
02786 start = end
02787 end += length
02788 if python3:
02789 self.action_goal.goal.options.selected_object.region.image.encoding = str[start:end].decode('utf-8')
02790 else:
02791 self.action_goal.goal.options.selected_object.region.image.encoding = str[start:end]
02792 _x = self
02793 start = end
02794 end += 5
02795 (_x.action_goal.goal.options.selected_object.region.image.is_bigendian, _x.action_goal.goal.options.selected_object.region.image.step,) = _struct_BI.unpack(str[start:end])
02796 start = end
02797 end += 4
02798 (length,) = _struct_I.unpack(str[start:end])
02799 start = end
02800 end += length
02801 if python3:
02802 self.action_goal.goal.options.selected_object.region.image.data = str[start:end].decode('utf-8')
02803 else:
02804 self.action_goal.goal.options.selected_object.region.image.data = str[start:end]
02805 _x = self
02806 start = end
02807 end += 12
02808 (_x.action_goal.goal.options.selected_object.region.disparity_image.header.seq, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.disparity_image.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
02809 start = end
02810 end += 4
02811 (length,) = _struct_I.unpack(str[start:end])
02812 start = end
02813 end += length
02814 if python3:
02815 self.action_goal.goal.options.selected_object.region.disparity_image.header.frame_id = str[start:end].decode('utf-8')
02816 else:
02817 self.action_goal.goal.options.selected_object.region.disparity_image.header.frame_id = str[start:end]
02818 _x = self
02819 start = end
02820 end += 8
02821 (_x.action_goal.goal.options.selected_object.region.disparity_image.height, _x.action_goal.goal.options.selected_object.region.disparity_image.width,) = _struct_2I.unpack(str[start:end])
02822 start = end
02823 end += 4
02824 (length,) = _struct_I.unpack(str[start:end])
02825 start = end
02826 end += length
02827 if python3:
02828 self.action_goal.goal.options.selected_object.region.disparity_image.encoding = str[start:end].decode('utf-8')
02829 else:
02830 self.action_goal.goal.options.selected_object.region.disparity_image.encoding = str[start:end]
02831 _x = self
02832 start = end
02833 end += 5
02834 (_x.action_goal.goal.options.selected_object.region.disparity_image.is_bigendian, _x.action_goal.goal.options.selected_object.region.disparity_image.step,) = _struct_BI.unpack(str[start:end])
02835 start = end
02836 end += 4
02837 (length,) = _struct_I.unpack(str[start:end])
02838 start = end
02839 end += length
02840 if python3:
02841 self.action_goal.goal.options.selected_object.region.disparity_image.data = str[start:end].decode('utf-8')
02842 else:
02843 self.action_goal.goal.options.selected_object.region.disparity_image.data = str[start:end]
02844 _x = self
02845 start = end
02846 end += 12
02847 (_x.action_goal.goal.options.selected_object.region.cam_info.header.seq, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.cam_info.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
02848 start = end
02849 end += 4
02850 (length,) = _struct_I.unpack(str[start:end])
02851 start = end
02852 end += length
02853 if python3:
02854 self.action_goal.goal.options.selected_object.region.cam_info.header.frame_id = str[start:end].decode('utf-8')
02855 else:
02856 self.action_goal.goal.options.selected_object.region.cam_info.header.frame_id = str[start:end]
02857 _x = self
02858 start = end
02859 end += 8
02860 (_x.action_goal.goal.options.selected_object.region.cam_info.height, _x.action_goal.goal.options.selected_object.region.cam_info.width,) = _struct_2I.unpack(str[start:end])
02861 start = end
02862 end += 4
02863 (length,) = _struct_I.unpack(str[start:end])
02864 start = end
02865 end += length
02866 if python3:
02867 self.action_goal.goal.options.selected_object.region.cam_info.distortion_model = str[start:end].decode('utf-8')
02868 else:
02869 self.action_goal.goal.options.selected_object.region.cam_info.distortion_model = str[start:end]
02870 start = end
02871 end += 4
02872 (length,) = _struct_I.unpack(str[start:end])
02873 pattern = '<%sd'%length
02874 start = end
02875 end += struct.calcsize(pattern)
02876 self.action_goal.goal.options.selected_object.region.cam_info.D = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
02877 start = end
02878 end += 72
02879 self.action_goal.goal.options.selected_object.region.cam_info.K = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=9)
02880 start = end
02881 end += 72
02882 self.action_goal.goal.options.selected_object.region.cam_info.R = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=9)
02883 start = end
02884 end += 96
02885 self.action_goal.goal.options.selected_object.region.cam_info.P = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=12)
02886 _x = self
02887 start = end
02888 end += 37
02889 (_x.action_goal.goal.options.selected_object.region.cam_info.binning_x, _x.action_goal.goal.options.selected_object.region.cam_info.binning_y, _x.action_goal.goal.options.selected_object.region.cam_info.roi.x_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.y_offset, _x.action_goal.goal.options.selected_object.region.cam_info.roi.height, _x.action_goal.goal.options.selected_object.region.cam_info.roi.width, _x.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.seq, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.secs, _x.action_goal.goal.options.selected_object.region.roi_box_pose.header.stamp.nsecs,) = _struct_6IB3I.unpack(str[start:end])
02890 self.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify = bool(self.action_goal.goal.options.selected_object.region.cam_info.roi.do_rectify)
02891 start = end
02892 end += 4
02893 (length,) = _struct_I.unpack(str[start:end])
02894 start = end
02895 end += length
02896 if python3:
02897 self.action_goal.goal.options.selected_object.region.roi_box_pose.header.frame_id = str[start:end].decode('utf-8')
02898 else:
02899 self.action_goal.goal.options.selected_object.region.roi_box_pose.header.frame_id = str[start:end]
02900 _x = self
02901 start = end
02902 end += 80
02903 (_x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.position.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.x, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.y, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.z, _x.action_goal.goal.options.selected_object.region.roi_box_pose.pose.orientation.w, _x.action_goal.goal.options.selected_object.region.roi_box_dims.x, _x.action_goal.goal.options.selected_object.region.roi_box_dims.y, _x.action_goal.goal.options.selected_object.region.roi_box_dims.z,) = _struct_10d.unpack(str[start:end])
02904 start = end
02905 end += 4
02906 (length,) = _struct_I.unpack(str[start:end])
02907 start = end
02908 end += length
02909 if python3:
02910 self.action_goal.goal.options.selected_object.collision_name = str[start:end].decode('utf-8')
02911 else:
02912 self.action_goal.goal.options.selected_object.collision_name = str[start:end]
02913 start = end
02914 end += 4
02915 (length,) = _struct_I.unpack(str[start:end])
02916 self.action_goal.goal.options.movable_obstacles = []
02917 for i in range(0, length):
02918 val1 = object_manipulation_msgs.msg.GraspableObject()
02919 start = end
02920 end += 4
02921 (length,) = _struct_I.unpack(str[start:end])
02922 start = end
02923 end += length
02924 if python3:
02925 val1.reference_frame_id = str[start:end].decode('utf-8')
02926 else:
02927 val1.reference_frame_id = str[start:end]
02928 start = end
02929 end += 4
02930 (length,) = _struct_I.unpack(str[start:end])
02931 val1.potential_models = []
02932 for i in range(0, length):
02933 val2 = household_objects_database_msgs.msg.DatabaseModelPose()
02934 start = end
02935 end += 4
02936 (val2.model_id,) = _struct_i.unpack(str[start:end])
02937 _v115 = val2.pose
02938 _v116 = _v115.header
02939 start = end
02940 end += 4
02941 (_v116.seq,) = _struct_I.unpack(str[start:end])
02942 _v117 = _v116.stamp
02943 _x = _v117
02944 start = end
02945 end += 8
02946 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
02947 start = end
02948 end += 4
02949 (length,) = _struct_I.unpack(str[start:end])
02950 start = end
02951 end += length
02952 if python3:
02953 _v116.frame_id = str[start:end].decode('utf-8')
02954 else:
02955 _v116.frame_id = str[start:end]
02956 _v118 = _v115.pose
02957 _v119 = _v118.position
02958 _x = _v119
02959 start = end
02960 end += 24
02961 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
02962 _v120 = _v118.orientation
02963 _x = _v120
02964 start = end
02965 end += 32
02966 (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
02967 start = end
02968 end += 4
02969 (val2.confidence,) = _struct_f.unpack(str[start:end])
02970 start = end
02971 end += 4
02972 (length,) = _struct_I.unpack(str[start:end])
02973 start = end
02974 end += length
02975 if python3:
02976 val2.detector_name = str[start:end].decode('utf-8')
02977 else:
02978 val2.detector_name = str[start:end]
02979 val1.potential_models.append(val2)
02980 _v121 = val1.cluster
02981 _v122 = _v121.header
02982 start = end
02983 end += 4
02984 (_v122.seq,) = _struct_I.unpack(str[start:end])
02985 _v123 = _v122.stamp
02986 _x = _v123
02987 start = end
02988 end += 8
02989 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
02990 start = end
02991 end += 4
02992 (length,) = _struct_I.unpack(str[start:end])
02993 start = end
02994 end += length
02995 if python3:
02996 _v122.frame_id = str[start:end].decode('utf-8')
02997 else:
02998 _v122.frame_id = str[start:end]
02999 start = end
03000 end += 4
03001 (length,) = _struct_I.unpack(str[start:end])
03002 _v121.points = []
03003 for i in range(0, length):
03004 val3 = geometry_msgs.msg.Point32()
03005 _x = val3
03006 start = end
03007 end += 12
03008 (_x.x, _x.y, _x.z,) = _struct_3f.unpack(str[start:end])
03009 _v121.points.append(val3)
03010 start = end
03011 end += 4
03012 (length,) = _struct_I.unpack(str[start:end])
03013 _v121.channels = []
03014 for i in range(0, length):
03015 val3 = sensor_msgs.msg.ChannelFloat32()
03016 start = end
03017 end += 4
03018 (length,) = _struct_I.unpack(str[start:end])
03019 start = end
03020 end += length
03021 if python3:
03022 val3.name = str[start:end].decode('utf-8')
03023 else:
03024 val3.name = str[start:end]
03025 start = end
03026 end += 4
03027 (length,) = _struct_I.unpack(str[start:end])
03028 pattern = '<%sf'%length
03029 start = end
03030 end += struct.calcsize(pattern)
03031 val3.values = numpy.frombuffer(str[start:end], dtype=numpy.float32, count=length)
03032 _v121.channels.append(val3)
03033 _v124 = val1.region
03034 _v125 = _v124.cloud
03035 _v126 = _v125.header
03036 start = end
03037 end += 4
03038 (_v126.seq,) = _struct_I.unpack(str[start:end])
03039 _v127 = _v126.stamp
03040 _x = _v127
03041 start = end
03042 end += 8
03043 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
03044 start = end
03045 end += 4
03046 (length,) = _struct_I.unpack(str[start:end])
03047 start = end
03048 end += length
03049 if python3:
03050 _v126.frame_id = str[start:end].decode('utf-8')
03051 else:
03052 _v126.frame_id = str[start:end]
03053 _x = _v125
03054 start = end
03055 end += 8
03056 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
03057 start = end
03058 end += 4
03059 (length,) = _struct_I.unpack(str[start:end])
03060 _v125.fields = []
03061 for i in range(0, length):
03062 val4 = sensor_msgs.msg.PointField()
03063 start = end
03064 end += 4
03065 (length,) = _struct_I.unpack(str[start:end])
03066 start = end
03067 end += length
03068 if python3:
03069 val4.name = str[start:end].decode('utf-8')
03070 else:
03071 val4.name = str[start:end]
03072 _x = val4
03073 start = end
03074 end += 9
03075 (_x.offset, _x.datatype, _x.count,) = _struct_IBI.unpack(str[start:end])
03076 _v125.fields.append(val4)
03077 _x = _v125
03078 start = end
03079 end += 9
03080 (_x.is_bigendian, _x.point_step, _x.row_step,) = _struct_B2I.unpack(str[start:end])
03081 _v125.is_bigendian = bool(_v125.is_bigendian)
03082 start = end
03083 end += 4
03084 (length,) = _struct_I.unpack(str[start:end])
03085 start = end
03086 end += length
03087 if python3:
03088 _v125.data = str[start:end].decode('utf-8')
03089 else:
03090 _v125.data = str[start:end]
03091 start = end
03092 end += 1
03093 (_v125.is_dense,) = _struct_B.unpack(str[start:end])
03094 _v125.is_dense = bool(_v125.is_dense)
03095 start = end
03096 end += 4
03097 (length,) = _struct_I.unpack(str[start:end])
03098 pattern = '<%si'%length
03099 start = end
03100 end += struct.calcsize(pattern)
03101 _v124.mask = numpy.frombuffer(str[start:end], dtype=numpy.int32, count=length)
03102 _v128 = _v124.image
03103 _v129 = _v128.header
03104 start = end
03105 end += 4
03106 (_v129.seq,) = _struct_I.unpack(str[start:end])
03107 _v130 = _v129.stamp
03108 _x = _v130
03109 start = end
03110 end += 8
03111 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
03112 start = end
03113 end += 4
03114 (length,) = _struct_I.unpack(str[start:end])
03115 start = end
03116 end += length
03117 if python3:
03118 _v129.frame_id = str[start:end].decode('utf-8')
03119 else:
03120 _v129.frame_id = str[start:end]
03121 _x = _v128
03122 start = end
03123 end += 8
03124 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
03125 start = end
03126 end += 4
03127 (length,) = _struct_I.unpack(str[start:end])
03128 start = end
03129 end += length
03130 if python3:
03131 _v128.encoding = str[start:end].decode('utf-8')
03132 else:
03133 _v128.encoding = str[start:end]
03134 _x = _v128
03135 start = end
03136 end += 5
03137 (_x.is_bigendian, _x.step,) = _struct_BI.unpack(str[start:end])
03138 start = end
03139 end += 4
03140 (length,) = _struct_I.unpack(str[start:end])
03141 start = end
03142 end += length
03143 if python3:
03144 _v128.data = str[start:end].decode('utf-8')
03145 else:
03146 _v128.data = str[start:end]
03147 _v131 = _v124.disparity_image
03148 _v132 = _v131.header
03149 start = end
03150 end += 4
03151 (_v132.seq,) = _struct_I.unpack(str[start:end])
03152 _v133 = _v132.stamp
03153 _x = _v133
03154 start = end
03155 end += 8
03156 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
03157 start = end
03158 end += 4
03159 (length,) = _struct_I.unpack(str[start:end])
03160 start = end
03161 end += length
03162 if python3:
03163 _v132.frame_id = str[start:end].decode('utf-8')
03164 else:
03165 _v132.frame_id = str[start:end]
03166 _x = _v131
03167 start = end
03168 end += 8
03169 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
03170 start = end
03171 end += 4
03172 (length,) = _struct_I.unpack(str[start:end])
03173 start = end
03174 end += length
03175 if python3:
03176 _v131.encoding = str[start:end].decode('utf-8')
03177 else:
03178 _v131.encoding = str[start:end]
03179 _x = _v131
03180 start = end
03181 end += 5
03182 (_x.is_bigendian, _x.step,) = _struct_BI.unpack(str[start:end])
03183 start = end
03184 end += 4
03185 (length,) = _struct_I.unpack(str[start:end])
03186 start = end
03187 end += length
03188 if python3:
03189 _v131.data = str[start:end].decode('utf-8')
03190 else:
03191 _v131.data = str[start:end]
03192 _v134 = _v124.cam_info
03193 _v135 = _v134.header
03194 start = end
03195 end += 4
03196 (_v135.seq,) = _struct_I.unpack(str[start:end])
03197 _v136 = _v135.stamp
03198 _x = _v136
03199 start = end
03200 end += 8
03201 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
03202 start = end
03203 end += 4
03204 (length,) = _struct_I.unpack(str[start:end])
03205 start = end
03206 end += length
03207 if python3:
03208 _v135.frame_id = str[start:end].decode('utf-8')
03209 else:
03210 _v135.frame_id = str[start:end]
03211 _x = _v134
03212 start = end
03213 end += 8
03214 (_x.height, _x.width,) = _struct_2I.unpack(str[start:end])
03215 start = end
03216 end += 4
03217 (length,) = _struct_I.unpack(str[start:end])
03218 start = end
03219 end += length
03220 if python3:
03221 _v134.distortion_model = str[start:end].decode('utf-8')
03222 else:
03223 _v134.distortion_model = str[start:end]
03224 start = end
03225 end += 4
03226 (length,) = _struct_I.unpack(str[start:end])
03227 pattern = '<%sd'%length
03228 start = end
03229 end += struct.calcsize(pattern)
03230 _v134.D = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
03231 start = end
03232 end += 72
03233 _v134.K = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=9)
03234 start = end
03235 end += 72
03236 _v134.R = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=9)
03237 start = end
03238 end += 96
03239 _v134.P = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=12)
03240 _x = _v134
03241 start = end
03242 end += 8
03243 (_x.binning_x, _x.binning_y,) = _struct_2I.unpack(str[start:end])
03244 _v137 = _v134.roi
03245 _x = _v137
03246 start = end
03247 end += 17
03248 (_x.x_offset, _x.y_offset, _x.height, _x.width, _x.do_rectify,) = _struct_4IB.unpack(str[start:end])
03249 _v137.do_rectify = bool(_v137.do_rectify)
03250 _v138 = _v124.roi_box_pose
03251 _v139 = _v138.header
03252 start = end
03253 end += 4
03254 (_v139.seq,) = _struct_I.unpack(str[start:end])
03255 _v140 = _v139.stamp
03256 _x = _v140
03257 start = end
03258 end += 8
03259 (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
03260 start = end
03261 end += 4
03262 (length,) = _struct_I.unpack(str[start:end])
03263 start = end
03264 end += length
03265 if python3:
03266 _v139.frame_id = str[start:end].decode('utf-8')
03267 else:
03268 _v139.frame_id = str[start:end]
03269 _v141 = _v138.pose
03270 _v142 = _v141.position
03271 _x = _v142
03272 start = end
03273 end += 24
03274 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
03275 _v143 = _v141.orientation
03276 _x = _v143
03277 start = end
03278 end += 32
03279 (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
03280 _v144 = _v124.roi_box_dims
03281 _x = _v144
03282 start = end
03283 end += 24
03284 (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
03285 start = end
03286 end += 4
03287 (length,) = _struct_I.unpack(str[start:end])
03288 start = end
03289 end += length
03290 if python3:
03291 val1.collision_name = str[start:end].decode('utf-8')
03292 else:
03293 val1.collision_name = str[start:end]
03294 self.action_goal.goal.options.movable_obstacles.append(val1)
03295 _x = self
03296 start = end
03297 end += 34
03298 (_x.action_goal.goal.options.adv_options.reactive_grasping, _x.action_goal.goal.options.adv_options.reactive_force, _x.action_goal.goal.options.adv_options.reactive_place, _x.action_goal.goal.options.adv_options.lift_steps, _x.action_goal.goal.options.adv_options.retreat_steps, _x.action_goal.goal.options.adv_options.lift_direction_choice, _x.action_goal.goal.options.adv_options.desired_approach, _x.action_goal.goal.options.adv_options.min_approach, _x.action_goal.goal.options.adv_options.max_contact_force, _x.action_goal.goal.options.adv_options.find_alternatives, _x.action_goal.goal.options.adv_options.always_plan_grasps, _x.action_goal.goal.options.adv_options.cycle_gripper_opening, _x.action_goal.goal.command.command,) = _struct_3B5if3Bi.unpack(str[start:end])
03299 self.action_goal.goal.options.adv_options.reactive_grasping = bool(self.action_goal.goal.options.adv_options.reactive_grasping)
03300 self.action_goal.goal.options.adv_options.reactive_force = bool(self.action_goal.goal.options.adv_options.reactive_force)
03301 self.action_goal.goal.options.adv_options.reactive_place = bool(self.action_goal.goal.options.adv_options.reactive_place)
03302 self.action_goal.goal.options.adv_options.find_alternatives = bool(self.action_goal.goal.options.adv_options.find_alternatives)
03303 self.action_goal.goal.options.adv_options.always_plan_grasps = bool(self.action_goal.goal.options.adv_options.always_plan_grasps)
03304 self.action_goal.goal.options.adv_options.cycle_gripper_opening = bool(self.action_goal.goal.options.adv_options.cycle_gripper_opening)
03305 start = end
03306 end += 4
03307 (length,) = _struct_I.unpack(str[start:end])
03308 start = end
03309 end += length
03310 if python3:
03311 self.action_goal.goal.command.script_name = str[start:end].decode('utf-8')
03312 else:
03313 self.action_goal.goal.command.script_name = str[start:end]
03314 start = end
03315 end += 4
03316 (length,) = _struct_I.unpack(str[start:end])
03317 start = end
03318 end += length
03319 if python3:
03320 self.action_goal.goal.command.script_group_name = str[start:end].decode('utf-8')
03321 else:
03322 self.action_goal.goal.command.script_group_name = str[start:end]
03323 _x = self
03324 start = end
03325 end += 12
03326 (_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
03327 start = end
03328 end += 4
03329 (length,) = _struct_I.unpack(str[start:end])
03330 start = end
03331 end += length
03332 if python3:
03333 self.action_result.header.frame_id = str[start:end].decode('utf-8')
03334 else:
03335 self.action_result.header.frame_id = str[start:end]
03336 _x = self
03337 start = end
03338 end += 8
03339 (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
03340 start = end
03341 end += 4
03342 (length,) = _struct_I.unpack(str[start:end])
03343 start = end
03344 end += length
03345 if python3:
03346 self.action_result.status.goal_id.id = str[start:end].decode('utf-8')
03347 else:
03348 self.action_result.status.goal_id.id = str[start:end]
03349 start = end
03350 end += 1
03351 (self.action_result.status.status,) = _struct_B.unpack(str[start:end])
03352 start = end
03353 end += 4
03354 (length,) = _struct_I.unpack(str[start:end])
03355 start = end
03356 end += length
03357 if python3:
03358 self.action_result.status.text = str[start:end].decode('utf-8')
03359 else:
03360 self.action_result.status.text = str[start:end]
03361 _x = self
03362 start = end
03363 end += 16
03364 (_x.action_result.result.result.value, _x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _struct_i3I.unpack(str[start:end])
03365 start = end
03366 end += 4
03367 (length,) = _struct_I.unpack(str[start:end])
03368 start = end
03369 end += length
03370 if python3:
03371 self.action_feedback.header.frame_id = str[start:end].decode('utf-8')
03372 else:
03373 self.action_feedback.header.frame_id = str[start:end]
03374 _x = self
03375 start = end
03376 end += 8
03377 (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _struct_2I.unpack(str[start:end])
03378 start = end
03379 end += 4
03380 (length,) = _struct_I.unpack(str[start:end])
03381 start = end
03382 end += length
03383 if python3:
03384 self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8')
03385 else:
03386 self.action_feedback.status.goal_id.id = str[start:end]
03387 start = end
03388 end += 1
03389 (self.action_feedback.status.status,) = _struct_B.unpack(str[start:end])
03390 start = end
03391 end += 4
03392 (length,) = _struct_I.unpack(str[start:end])
03393 start = end
03394 end += length
03395 if python3:
03396 self.action_feedback.status.text = str[start:end].decode('utf-8')
03397 else:
03398 self.action_feedback.status.text = str[start:end]
03399 start = end
03400 end += 4
03401 (length,) = _struct_I.unpack(str[start:end])
03402 start = end
03403 end += length
03404 if python3:
03405 self.action_feedback.feedback.status = str[start:end].decode('utf-8')
03406 else:
03407 self.action_feedback.feedback.status = str[start:end]
03408 return self
03409 except struct.error as e:
03410 raise genpy.DeserializationError(e) #most likely buffer underfill
03411
03412 _struct_I = genpy.struct_I
03413 _struct_IBI = struct.Struct("<IBI")
03414 _struct_6IB3I = struct.Struct("<6IB3I")
03415 _struct_B = struct.Struct("<B")
03416 _struct_12d = struct.Struct("<12d")
03417 _struct_f = struct.Struct("<f")
03418 _struct_i = struct.Struct("<i")
03419 _struct_4d = struct.Struct("<4d")
03420 _struct_10d = struct.Struct("<10d")
03421 _struct_3f = struct.Struct("<3f")
03422 _struct_3I = struct.Struct("<3I")
03423 _struct_9d = struct.Struct("<9d")
03424 _struct_B2I = struct.Struct("<B2I")
03425 _struct_i3I = struct.Struct("<i3I")
03426 _struct_B6i = struct.Struct("<B6i")
03427 _struct_3B5if3Bi = struct.Struct("<3B5if3Bi")
03428 _struct_BI = struct.Struct("<BI")
03429 _struct_2I = struct.Struct("<2I")
03430 _struct_4IB = struct.Struct("<4IB")
03431 _struct_3d = struct.Struct("<3d")