# This Python file uses the following encoding: utf-8
"""autogenerated by genpy from grasping_msgs/GraspPlanningAction.msg. Do not edit."""
import codecs
import sys
python3 = True if sys.hexversion > 0x03000000 else False
import genpy
import struct

import actionlib_msgs.msg
import genpy
import geometry_msgs.msg
import grasping_msgs.msg
import moveit_msgs.msg
import sensor_msgs.msg
import shape_msgs.msg
import std_msgs.msg
import trajectory_msgs.msg

class GraspPlanningAction(genpy.Message):
  _md5sum = "7133eaf5c7bbf3f1f2b109ce543a58b0"
  _type = "grasping_msgs/GraspPlanningAction"
  _has_header = False  # flag to mark the presence of a Header object
  _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

GraspPlanningActionGoal action_goal
GraspPlanningActionResult action_result
GraspPlanningActionFeedback action_feedback

================================================================================
MSG: grasping_msgs/GraspPlanningActionGoal
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

Header header
actionlib_msgs/GoalID goal_id
GraspPlanningGoal goal

================================================================================
MSG: std_msgs/Header
# Standard metadata for higher-level stamped data types.
# This is generally used to communicate timestamped data 
# in a particular coordinate frame.
# 
# sequence ID: consecutively increasing ID 
uint32 seq
#Two-integer timestamp that is expressed as:
# * stamp.sec: seconds (stamp_secs) since epoch (in Python the variable is called 'secs')
# * stamp.nsec: nanoseconds since stamp_secs (in Python the variable is called 'nsecs')
# time-handling sugar is provided by the client library
time stamp
#Frame this data is associated with
string frame_id

================================================================================
MSG: actionlib_msgs/GoalID
# The stamp should store the time at which this goal was requested.
# It is used by an action server when it tries to preempt all
# goals that were requested before a certain time
time stamp

# The id provides a way to associate feedback and
# result message with specific goal requests. The id
# specified must be unique.
string id


================================================================================
MSG: grasping_msgs/GraspPlanningGoal
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
###########################################################
# This action is used when planning grasps for a single,
#  already known object, one object at a time.

# Object for which grasp planning is requested
Object object

# Name of group to plan with (optional)
string group_name

================================================================================
MSG: grasping_msgs/Object
###########################################################
# This message describes an object.

# Many of the geometric items below lack a stamp/frame_id,
# header stamp/frame_id should be used there
std_msgs/Header header

# An object might have a name
string name

# An object might have a known (named) support surface
string support_surface

# Objects might have properties, such as type/class, or color, etc.
ObjectProperty[] properties

###########################################################
# Objects have many possible descriptions
#  The following are the possible description formats

# Perception modules often represent an object as a cluster of points
#  Is considered valid if number of points > 0
sensor_msgs/PointCloud2 point_cluster

# MoveIt prefers solid primitives or meshes as a description of objects
shape_msgs/SolidPrimitive[] primitives
geometry_msgs/Pose[] primitive_poses

shape_msgs/Mesh[] meshes
geometry_msgs/Pose[] mesh_poses

# An object representing a support surface might be described by a plane
# Is considered valid if coefficients are not all 0s.
shape_msgs/Plane surface

================================================================================
MSG: grasping_msgs/ObjectProperty
###########################################################
# Other generic properties of an object
string name
string value

================================================================================
MSG: sensor_msgs/PointCloud2
# This message holds a collection of N-dimensional points, which may
# contain additional information such as normals, intensity, etc. The
# point data is stored as a binary blob, its layout described by the
# contents of the "fields" array.

# The point cloud data may be organized 2d (image-like) or 1d
# (unordered). Point clouds organized as 2d images may be produced by
# camera depth sensors such as stereo or time-of-flight.

# Time of sensor data acquisition, and the coordinate frame ID (for 3d
# points).
Header header

# 2D structure of the point cloud. If the cloud is unordered, height is
# 1 and width is the length of the point cloud.
uint32 height
uint32 width

# Describes the channels and their layout in the binary data blob.
PointField[] fields

bool    is_bigendian # Is this data bigendian?
uint32  point_step   # Length of a point in bytes
uint32  row_step     # Length of a row in bytes
uint8[] data         # Actual point data, size is (row_step*height)

bool is_dense        # True if there are no invalid points

================================================================================
MSG: sensor_msgs/PointField
# This message holds the description of one point entry in the
# PointCloud2 message format.
uint8 INT8    = 1
uint8 UINT8   = 2
uint8 INT16   = 3
uint8 UINT16  = 4
uint8 INT32   = 5
uint8 UINT32  = 6
uint8 FLOAT32 = 7
uint8 FLOAT64 = 8

string name      # Name of field
uint32 offset    # Offset from start of point struct
uint8  datatype  # Datatype enumeration, see above
uint32 count     # How many elements in the field

================================================================================
MSG: shape_msgs/SolidPrimitive
# Define box, sphere, cylinder, cone 
# All shapes are defined to have their bounding boxes centered around 0,0,0.

uint8 BOX=1
uint8 SPHERE=2
uint8 CYLINDER=3
uint8 CONE=4

# The type of the shape
uint8 type


# The dimensions of the shape
float64[] dimensions

# The meaning of the shape dimensions: each constant defines the index in the 'dimensions' array

# For the BOX type, the X, Y, and Z dimensions are the length of the corresponding
# sides of the box.
uint8 BOX_X=0
uint8 BOX_Y=1
uint8 BOX_Z=2


# For the SPHERE type, only one component is used, and it gives the radius of
# the sphere.
uint8 SPHERE_RADIUS=0


# For the CYLINDER and CONE types, the center line is oriented along
# the Z axis.  Therefore the CYLINDER_HEIGHT (CONE_HEIGHT) component
# of dimensions gives the height of the cylinder (cone).  The
# CYLINDER_RADIUS (CONE_RADIUS) component of dimensions gives the
# radius of the base of the cylinder (cone).  Cone and cylinder
# primitives are defined to be circular. The tip of the cone is
# pointing up, along +Z axis.

uint8 CYLINDER_HEIGHT=0
uint8 CYLINDER_RADIUS=1

uint8 CONE_HEIGHT=0
uint8 CONE_RADIUS=1

================================================================================
MSG: geometry_msgs/Pose
# A representation of pose in free space, composed of position and orientation. 
Point position
Quaternion orientation

================================================================================
MSG: geometry_msgs/Point
# This contains the position of a point in free space
float64 x
float64 y
float64 z

================================================================================
MSG: geometry_msgs/Quaternion
# This represents an orientation in free space in quaternion form.

float64 x
float64 y
float64 z
float64 w

================================================================================
MSG: shape_msgs/Mesh
# Definition of a mesh

# list of triangles; the index values refer to positions in vertices[]
MeshTriangle[] triangles

# the actual vertices that make up the mesh
geometry_msgs/Point[] vertices

================================================================================
MSG: shape_msgs/MeshTriangle
# Definition of a triangle's vertices
uint32[3] vertex_indices

================================================================================
MSG: shape_msgs/Plane
# Representation of a plane, using the plane equation ax + by + cz + d = 0

# a := coef[0]
# b := coef[1]
# c := coef[2]
# d := coef[3]

float64[4] coef

================================================================================
MSG: grasping_msgs/GraspPlanningActionResult
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

Header header
actionlib_msgs/GoalStatus status
GraspPlanningResult result

================================================================================
MSG: actionlib_msgs/GoalStatus
GoalID goal_id
uint8 status
uint8 PENDING         = 0   # The goal has yet to be processed by the action server
uint8 ACTIVE          = 1   # The goal is currently being processed by the action server
uint8 PREEMPTED       = 2   # The goal received a cancel request after it started executing
                            #   and has since completed its execution (Terminal State)
uint8 SUCCEEDED       = 3   # The goal was achieved successfully by the action server (Terminal State)
uint8 ABORTED         = 4   # The goal was aborted during execution by the action server due
                            #    to some failure (Terminal State)
uint8 REJECTED        = 5   # The goal was rejected by the action server without being processed,
                            #    because the goal was unattainable or invalid (Terminal State)
uint8 PREEMPTING      = 6   # The goal received a cancel request after it started executing
                            #    and has not yet completed execution
uint8 RECALLING       = 7   # The goal received a cancel request before it started executing,
                            #    but the action server has not yet confirmed that the goal is canceled
uint8 RECALLED        = 8   # The goal received a cancel request before it started executing
                            #    and was successfully cancelled (Terminal State)
uint8 LOST            = 9   # An action client can determine that a goal is LOST. This should not be
                            #    sent over the wire by an action server

#Allow for the user to associate a string with GoalStatus for debugging
string text


================================================================================
MSG: grasping_msgs/GraspPlanningResult
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
# All grasps
moveit_msgs/Grasp[] grasps

================================================================================
MSG: moveit_msgs/Grasp
# This message contains a description of a grasp that would be used
# with a particular end-effector to grasp an object, including how to
# approach it, grip it, etc.  This message does not contain any
# information about a "grasp point" (a position ON the object).
# Whatever generates this message should have already combined
# information about grasp points with information about the geometry
# of the end-effector to compute the grasp_pose in this message.

# A name for this grasp
string id

# The internal posture of the hand for the pre-grasp
# only positions are used
trajectory_msgs/JointTrajectory pre_grasp_posture

# The internal posture of the hand for the grasp
# positions and efforts are used
trajectory_msgs/JointTrajectory grasp_posture

# The position of the end-effector for the grasp.  This is the pose of
# the "parent_link" of the end-effector, not actually the pose of any
# link *in* the end-effector.  Typically this would be the pose of the
# most distal wrist link before the hand (end-effector) links began.
geometry_msgs/PoseStamped grasp_pose

# The estimated probability of success for this grasp, or some other
# measure of how "good" it is.
float64 grasp_quality

# The approach direction to take before picking an object
GripperTranslation pre_grasp_approach

# The retreat direction to take after a grasp has been completed (object is attached)
GripperTranslation post_grasp_retreat

# The retreat motion to perform when releasing the object; this information
# is not necessary for the grasp itself, but when releasing the object,
# the information will be necessary. The grasp used to perform a pickup
# is returned as part of the result, so this information is available for 
# later use.
GripperTranslation post_place_retreat

# the maximum contact force to use while grasping (<=0 to disable)
float32 max_contact_force

# an optional list of obstacles that we have semantic information about
# and that can be touched/pushed/moved in the course of grasping
string[] allowed_touch_objects

================================================================================
MSG: trajectory_msgs/JointTrajectory
Header header
string[] joint_names
JointTrajectoryPoint[] points

================================================================================
MSG: trajectory_msgs/JointTrajectoryPoint
# Each trajectory point specifies either positions[, velocities[, accelerations]]
# or positions[, effort] for the trajectory to be executed.
# All specified values are in the same order as the joint names in JointTrajectory.msg

float64[] positions
float64[] velocities
float64[] accelerations
float64[] effort
duration time_from_start

================================================================================
MSG: geometry_msgs/PoseStamped
# A Pose with reference coordinate frame and timestamp
Header header
Pose pose

================================================================================
MSG: moveit_msgs/GripperTranslation
# defines a translation for the gripper, used in pickup or place tasks
# for example for lifting an object off a table or approaching the table for placing

# the direction of the translation
geometry_msgs/Vector3Stamped direction

# the desired translation distance
float32 desired_distance

# the min distance that must be considered feasible before the
# grasp is even attempted
float32 min_distance

================================================================================
MSG: geometry_msgs/Vector3Stamped
# This represents a Vector3 with reference coordinate frame and timestamp
Header header
Vector3 vector

================================================================================
MSG: geometry_msgs/Vector3
# This represents a vector in free space. 
# It is only meant to represent a direction. Therefore, it does not
# make sense to apply a translation to it (e.g., when applying a 
# generic rigid transformation to a Vector3, tf2 will only apply the
# rotation). If you want your data to be translatable too, use the
# geometry_msgs/Point message instead.

float64 x
float64 y
float64 z
================================================================================
MSG: grasping_msgs/GraspPlanningActionFeedback
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

Header header
actionlib_msgs/GoalStatus status
GraspPlanningFeedback feedback

================================================================================
MSG: grasping_msgs/GraspPlanningFeedback
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
# Grasps found thus far
moveit_msgs/Grasp[] grasps

"""
  __slots__ = ['action_goal','action_result','action_feedback']
  _slot_types = ['grasping_msgs/GraspPlanningActionGoal','grasping_msgs/GraspPlanningActionResult','grasping_msgs/GraspPlanningActionFeedback']

  def __init__(self, *args, **kwds):
    """
    Constructor. Any message fields that are implicitly/explicitly
    set to None will be assigned a default value. The recommend
    use is keyword arguments as this is more robust to future message
    changes.  You cannot mix in-order arguments and keyword arguments.

    The available fields are:
       action_goal,action_result,action_feedback

    :param args: complete set of field values, in .msg order
    :param kwds: use keyword arguments corresponding to message field names
    to set specific fields.
    """
    if args or kwds:
      super(GraspPlanningAction, self).__init__(*args, **kwds)
      # message fields cannot be None, assign default values for those that are
      if self.action_goal is None:
        self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      if self.action_result is None:
        self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      if self.action_feedback is None:
        self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()
    else:
      self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()

  def _get_types(self):
    """
    internal API method
    """
    return self._slot_types

  def serialize(self, buff):
    """
    serialize message into buffer
    :param buff: buffer, ``StringIO``
    """
    try:
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
      _x = self.action_goal.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
      _x = self.action_goal.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs))
      _x = self.action_goal.goal.object.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.support_surface
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_goal.goal.object.properties)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.properties:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1.value
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs))
      _x = self.action_goal.goal.object.point_cluster.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width))
      length = len(self.action_goal.goal.object.point_cluster.fields)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.point_cluster.fields:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1
        buff.write(_get_struct_IBI().pack(_x.offset, _x.datatype, _x.count))
      _x = self
      buff.write(_get_struct_B2I().pack(_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step))
      _x = self.action_goal.goal.object.point_cluster.data
      length = len(_x)
      # - if encoded as a list instead, serialize as bytes instead of string
      if type(_x) in [list, tuple]:
        buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
      else:
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.point_cluster.is_dense
      buff.write(_get_struct_B().pack(_x))
      length = len(self.action_goal.goal.object.primitives)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitives:
        _x = val1.type
        buff.write(_get_struct_B().pack(_x))
        length = len(val1.dimensions)
        buff.write(_struct_I.pack(length))
        pattern = '<%sd'%length
        buff.write(struct.Struct(pattern).pack(*val1.dimensions))
      length = len(self.action_goal.goal.object.primitive_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitive_poses:
        _v1 = val1.position
        _x = _v1
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v2 = val1.orientation
        _x = _v2
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      length = len(self.action_goal.goal.object.meshes)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.meshes:
        length = len(val1.triangles)
        buff.write(_struct_I.pack(length))
        for val2 in val1.triangles:
          buff.write(_get_struct_3I().pack(*val2.vertex_indices))
        length = len(val1.vertices)
        buff.write(_struct_I.pack(length))
        for val2 in val1.vertices:
          _x = val2
          buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
      length = len(self.action_goal.goal.object.mesh_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.mesh_poses:
        _v3 = val1.position
        _x = _v3
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v4 = val1.orientation
        _x = _v4
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      buff.write(_get_struct_4d().pack(*self.action_goal.goal.object.surface.coef))
      _x = self.action_goal.goal.group_name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
      _x = self.action_result.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
      _x = self.action_result.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_result.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_result.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_result.result.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_result.result.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v5 = val1.pre_grasp_posture
        _v6 = _v5.header
        _x = _v6.seq
        buff.write(_get_struct_I().pack(_x))
        _v7 = _v6.stamp
        _x = _v7
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v6.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v5.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v5.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v5.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v5.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v8 = val3.time_from_start
          _x = _v8
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v9 = val1.grasp_posture
        _v10 = _v9.header
        _x = _v10.seq
        buff.write(_get_struct_I().pack(_x))
        _v11 = _v10.stamp
        _x = _v11
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v10.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v9.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v9.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v9.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v9.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v12 = val3.time_from_start
          _x = _v12
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v13 = val1.grasp_pose
        _v14 = _v13.header
        _x = _v14.seq
        buff.write(_get_struct_I().pack(_x))
        _v15 = _v14.stamp
        _x = _v15
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v14.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v16 = _v13.pose
        _v17 = _v16.position
        _x = _v17
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v18 = _v16.orientation
        _x = _v18
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v19 = val1.pre_grasp_approach
        _v20 = _v19.direction
        _v21 = _v20.header
        _x = _v21.seq
        buff.write(_get_struct_I().pack(_x))
        _v22 = _v21.stamp
        _x = _v22
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v21.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v23 = _v20.vector
        _x = _v23
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v19
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v24 = val1.post_grasp_retreat
        _v25 = _v24.direction
        _v26 = _v25.header
        _x = _v26.seq
        buff.write(_get_struct_I().pack(_x))
        _v27 = _v26.stamp
        _x = _v27
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v26.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v28 = _v25.vector
        _x = _v28
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v24
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v29 = val1.post_place_retreat
        _v30 = _v29.direction
        _v31 = _v30.header
        _x = _v31.seq
        buff.write(_get_struct_I().pack(_x))
        _v32 = _v31.stamp
        _x = _v32
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v31.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v33 = _v30.vector
        _x = _v33
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v29
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
      _x = self.action_feedback.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
      _x = self.action_feedback.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_feedback.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_feedback.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_feedback.feedback.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_feedback.feedback.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v34 = val1.pre_grasp_posture
        _v35 = _v34.header
        _x = _v35.seq
        buff.write(_get_struct_I().pack(_x))
        _v36 = _v35.stamp
        _x = _v36
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v35.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v34.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v34.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v34.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v34.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v37 = val3.time_from_start
          _x = _v37
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v38 = val1.grasp_posture
        _v39 = _v38.header
        _x = _v39.seq
        buff.write(_get_struct_I().pack(_x))
        _v40 = _v39.stamp
        _x = _v40
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v39.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v38.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v38.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v38.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v38.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v41 = val3.time_from_start
          _x = _v41
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v42 = val1.grasp_pose
        _v43 = _v42.header
        _x = _v43.seq
        buff.write(_get_struct_I().pack(_x))
        _v44 = _v43.stamp
        _x = _v44
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v43.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v45 = _v42.pose
        _v46 = _v45.position
        _x = _v46
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v47 = _v45.orientation
        _x = _v47
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v48 = val1.pre_grasp_approach
        _v49 = _v48.direction
        _v50 = _v49.header
        _x = _v50.seq
        buff.write(_get_struct_I().pack(_x))
        _v51 = _v50.stamp
        _x = _v51
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v50.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v52 = _v49.vector
        _x = _v52
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v48
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v53 = val1.post_grasp_retreat
        _v54 = _v53.direction
        _v55 = _v54.header
        _x = _v55.seq
        buff.write(_get_struct_I().pack(_x))
        _v56 = _v55.stamp
        _x = _v56
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v55.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v57 = _v54.vector
        _x = _v57
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v53
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v58 = val1.post_place_retreat
        _v59 = _v58.direction
        _v60 = _v59.header
        _x = _v60.seq
        buff.write(_get_struct_I().pack(_x))
        _v61 = _v60.stamp
        _x = _v61
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v60.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v62 = _v59.vector
        _x = _v62
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v58
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
    except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
    except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))

  def deserialize(self, str):
    """
    unpack serialized message in str into this message instance
    :param str: byte array of serialized message, ``str``
    """
    codecs.lookup_error("rosmsg").msg_type = self._type
    try:
      if self.action_goal is None:
        self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      if self.action_result is None:
        self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      if self.action_feedback is None:
        self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()
      end = 0
      _x = self
      start = end
      end += 12
      (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal_id.id = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.header.frame_id = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.name = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.support_surface = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.support_surface = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.properties = []
      for i in range(0, length):
        val1 = grasping_msgs.msg.ObjectProperty()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.value = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.value = str[start:end]
        self.action_goal.goal.object.properties.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.fields = []
      for i in range(0, length):
        val1 = sensor_msgs.msg.PointField()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        _x = val1
        start = end
        end += 9
        (_x.offset, _x.datatype, _x.count,) = _get_struct_IBI().unpack(str[start:end])
        self.action_goal.goal.object.point_cluster.fields.append(val1)
      _x = self
      start = end
      end += 9
      (_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step,) = _get_struct_B2I().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_bigendian = bool(self.action_goal.goal.object.point_cluster.is_bigendian)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      self.action_goal.goal.object.point_cluster.data = str[start:end]
      start = end
      end += 1
      (self.action_goal.goal.object.point_cluster.is_dense,) = _get_struct_B().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_dense = bool(self.action_goal.goal.object.point_cluster.is_dense)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitives = []
      for i in range(0, length):
        val1 = shape_msgs.msg.SolidPrimitive()
        start = end
        end += 1
        (val1.type,) = _get_struct_B().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        pattern = '<%sd'%length
        start = end
        s = struct.Struct(pattern)
        end += s.size
        val1.dimensions = s.unpack(str[start:end])
        self.action_goal.goal.object.primitives.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitive_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v63 = val1.position
        _x = _v63
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v64 = val1.orientation
        _x = _v64
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.primitive_poses.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.meshes = []
      for i in range(0, length):
        val1 = shape_msgs.msg.Mesh()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.triangles = []
        for i in range(0, length):
          val2 = shape_msgs.msg.MeshTriangle()
          start = end
          end += 12
          val2.vertex_indices = _get_struct_3I().unpack(str[start:end])
          val1.triangles.append(val2)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.vertices = []
        for i in range(0, length):
          val2 = geometry_msgs.msg.Point()
          _x = val2
          start = end
          end += 24
          (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
          val1.vertices.append(val2)
        self.action_goal.goal.object.meshes.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.mesh_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v65 = val1.position
        _x = _v65
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v66 = val1.orientation
        _x = _v66
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.mesh_poses.append(val1)
      start = end
      end += 32
      self.action_goal.goal.object.surface.coef = _get_struct_4d().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.group_name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.group_name = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_result.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_result.result.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v67 = val1.pre_grasp_posture
        _v68 = _v67.header
        start = end
        end += 4
        (_v68.seq,) = _get_struct_I().unpack(str[start:end])
        _v69 = _v68.stamp
        _x = _v69
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v68.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v68.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v67.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v67.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v67.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v70 = val3.time_from_start
          _x = _v70
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v67.points.append(val3)
        _v71 = val1.grasp_posture
        _v72 = _v71.header
        start = end
        end += 4
        (_v72.seq,) = _get_struct_I().unpack(str[start:end])
        _v73 = _v72.stamp
        _x = _v73
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v72.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v72.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v71.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v71.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v71.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v74 = val3.time_from_start
          _x = _v74
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v71.points.append(val3)
        _v75 = val1.grasp_pose
        _v76 = _v75.header
        start = end
        end += 4
        (_v76.seq,) = _get_struct_I().unpack(str[start:end])
        _v77 = _v76.stamp
        _x = _v77
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v76.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v76.frame_id = str[start:end]
        _v78 = _v75.pose
        _v79 = _v78.position
        _x = _v79
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v80 = _v78.orientation
        _x = _v80
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v81 = val1.pre_grasp_approach
        _v82 = _v81.direction
        _v83 = _v82.header
        start = end
        end += 4
        (_v83.seq,) = _get_struct_I().unpack(str[start:end])
        _v84 = _v83.stamp
        _x = _v84
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v83.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v83.frame_id = str[start:end]
        _v85 = _v82.vector
        _x = _v85
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v81
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v86 = val1.post_grasp_retreat
        _v87 = _v86.direction
        _v88 = _v87.header
        start = end
        end += 4
        (_v88.seq,) = _get_struct_I().unpack(str[start:end])
        _v89 = _v88.stamp
        _x = _v89
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v88.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v88.frame_id = str[start:end]
        _v90 = _v87.vector
        _x = _v90
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v86
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v91 = val1.post_place_retreat
        _v92 = _v91.direction
        _v93 = _v92.header
        start = end
        end += 4
        (_v93.seq,) = _get_struct_I().unpack(str[start:end])
        _v94 = _v93.stamp
        _x = _v94
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v93.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v93.frame_id = str[start:end]
        _v95 = _v92.vector
        _x = _v95
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v91
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_result.result.grasps.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_feedback.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_feedback.feedback.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v96 = val1.pre_grasp_posture
        _v97 = _v96.header
        start = end
        end += 4
        (_v97.seq,) = _get_struct_I().unpack(str[start:end])
        _v98 = _v97.stamp
        _x = _v98
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v97.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v97.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v96.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v96.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v96.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v99 = val3.time_from_start
          _x = _v99
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v96.points.append(val3)
        _v100 = val1.grasp_posture
        _v101 = _v100.header
        start = end
        end += 4
        (_v101.seq,) = _get_struct_I().unpack(str[start:end])
        _v102 = _v101.stamp
        _x = _v102
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v101.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v101.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v100.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v100.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v100.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v103 = val3.time_from_start
          _x = _v103
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v100.points.append(val3)
        _v104 = val1.grasp_pose
        _v105 = _v104.header
        start = end
        end += 4
        (_v105.seq,) = _get_struct_I().unpack(str[start:end])
        _v106 = _v105.stamp
        _x = _v106
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v105.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v105.frame_id = str[start:end]
        _v107 = _v104.pose
        _v108 = _v107.position
        _x = _v108
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v109 = _v107.orientation
        _x = _v109
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v110 = val1.pre_grasp_approach
        _v111 = _v110.direction
        _v112 = _v111.header
        start = end
        end += 4
        (_v112.seq,) = _get_struct_I().unpack(str[start:end])
        _v113 = _v112.stamp
        _x = _v113
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v112.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v112.frame_id = str[start:end]
        _v114 = _v111.vector
        _x = _v114
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v110
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v115 = val1.post_grasp_retreat
        _v116 = _v115.direction
        _v117 = _v116.header
        start = end
        end += 4
        (_v117.seq,) = _get_struct_I().unpack(str[start:end])
        _v118 = _v117.stamp
        _x = _v118
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v117.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v117.frame_id = str[start:end]
        _v119 = _v116.vector
        _x = _v119
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v115
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v120 = val1.post_place_retreat
        _v121 = _v120.direction
        _v122 = _v121.header
        start = end
        end += 4
        (_v122.seq,) = _get_struct_I().unpack(str[start:end])
        _v123 = _v122.stamp
        _x = _v123
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v122.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v122.frame_id = str[start:end]
        _v124 = _v121.vector
        _x = _v124
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v120
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_feedback.feedback.grasps.append(val1)
      return self
    except struct.error as e:
      raise genpy.DeserializationError(e)  # most likely buffer underfill


  def serialize_numpy(self, buff, numpy):
    """
    serialize message with numpy array types into buffer
    :param buff: buffer, ``StringIO``
    :param numpy: numpy python module
    """
    try:
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
      _x = self.action_goal.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
      _x = self.action_goal.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs))
      _x = self.action_goal.goal.object.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.support_surface
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_goal.goal.object.properties)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.properties:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1.value
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs))
      _x = self.action_goal.goal.object.point_cluster.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width))
      length = len(self.action_goal.goal.object.point_cluster.fields)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.point_cluster.fields:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1
        buff.write(_get_struct_IBI().pack(_x.offset, _x.datatype, _x.count))
      _x = self
      buff.write(_get_struct_B2I().pack(_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step))
      _x = self.action_goal.goal.object.point_cluster.data
      length = len(_x)
      # - if encoded as a list instead, serialize as bytes instead of string
      if type(_x) in [list, tuple]:
        buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
      else:
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.point_cluster.is_dense
      buff.write(_get_struct_B().pack(_x))
      length = len(self.action_goal.goal.object.primitives)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitives:
        _x = val1.type
        buff.write(_get_struct_B().pack(_x))
        length = len(val1.dimensions)
        buff.write(_struct_I.pack(length))
        pattern = '<%sd'%length
        buff.write(val1.dimensions.tostring())
      length = len(self.action_goal.goal.object.primitive_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitive_poses:
        _v125 = val1.position
        _x = _v125
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v126 = val1.orientation
        _x = _v126
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      length = len(self.action_goal.goal.object.meshes)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.meshes:
        length = len(val1.triangles)
        buff.write(_struct_I.pack(length))
        for val2 in val1.triangles:
          buff.write(val2.vertex_indices.tostring())
        length = len(val1.vertices)
        buff.write(_struct_I.pack(length))
        for val2 in val1.vertices:
          _x = val2
          buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
      length = len(self.action_goal.goal.object.mesh_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.mesh_poses:
        _v127 = val1.position
        _x = _v127
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v128 = val1.orientation
        _x = _v128
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      buff.write(self.action_goal.goal.object.surface.coef.tostring())
      _x = self.action_goal.goal.group_name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
      _x = self.action_result.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
      _x = self.action_result.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_result.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_result.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_result.result.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_result.result.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v129 = val1.pre_grasp_posture
        _v130 = _v129.header
        _x = _v130.seq
        buff.write(_get_struct_I().pack(_x))
        _v131 = _v130.stamp
        _x = _v131
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v130.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v129.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v129.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v129.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v129.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v132 = val3.time_from_start
          _x = _v132
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v133 = val1.grasp_posture
        _v134 = _v133.header
        _x = _v134.seq
        buff.write(_get_struct_I().pack(_x))
        _v135 = _v134.stamp
        _x = _v135
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v134.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v133.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v133.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v133.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v133.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v136 = val3.time_from_start
          _x = _v136
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v137 = val1.grasp_pose
        _v138 = _v137.header
        _x = _v138.seq
        buff.write(_get_struct_I().pack(_x))
        _v139 = _v138.stamp
        _x = _v139
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v138.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v140 = _v137.pose
        _v141 = _v140.position
        _x = _v141
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v142 = _v140.orientation
        _x = _v142
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v143 = val1.pre_grasp_approach
        _v144 = _v143.direction
        _v145 = _v144.header
        _x = _v145.seq
        buff.write(_get_struct_I().pack(_x))
        _v146 = _v145.stamp
        _x = _v146
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v145.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v147 = _v144.vector
        _x = _v147
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v143
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v148 = val1.post_grasp_retreat
        _v149 = _v148.direction
        _v150 = _v149.header
        _x = _v150.seq
        buff.write(_get_struct_I().pack(_x))
        _v151 = _v150.stamp
        _x = _v151
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v150.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v152 = _v149.vector
        _x = _v152
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v148
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v153 = val1.post_place_retreat
        _v154 = _v153.direction
        _v155 = _v154.header
        _x = _v155.seq
        buff.write(_get_struct_I().pack(_x))
        _v156 = _v155.stamp
        _x = _v156
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v155.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v157 = _v154.vector
        _x = _v157
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v153
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
      _x = self.action_feedback.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
      _x = self.action_feedback.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_feedback.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_feedback.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_feedback.feedback.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_feedback.feedback.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v158 = val1.pre_grasp_posture
        _v159 = _v158.header
        _x = _v159.seq
        buff.write(_get_struct_I().pack(_x))
        _v160 = _v159.stamp
        _x = _v160
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v159.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v158.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v158.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v158.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v158.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v161 = val3.time_from_start
          _x = _v161
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v162 = val1.grasp_posture
        _v163 = _v162.header
        _x = _v163.seq
        buff.write(_get_struct_I().pack(_x))
        _v164 = _v163.stamp
        _x = _v164
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v163.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v162.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v162.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v162.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v162.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v165 = val3.time_from_start
          _x = _v165
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v166 = val1.grasp_pose
        _v167 = _v166.header
        _x = _v167.seq
        buff.write(_get_struct_I().pack(_x))
        _v168 = _v167.stamp
        _x = _v168
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v167.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v169 = _v166.pose
        _v170 = _v169.position
        _x = _v170
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v171 = _v169.orientation
        _x = _v171
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v172 = val1.pre_grasp_approach
        _v173 = _v172.direction
        _v174 = _v173.header
        _x = _v174.seq
        buff.write(_get_struct_I().pack(_x))
        _v175 = _v174.stamp
        _x = _v175
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v174.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v176 = _v173.vector
        _x = _v176
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v172
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v177 = val1.post_grasp_retreat
        _v178 = _v177.direction
        _v179 = _v178.header
        _x = _v179.seq
        buff.write(_get_struct_I().pack(_x))
        _v180 = _v179.stamp
        _x = _v180
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v179.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v181 = _v178.vector
        _x = _v181
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v177
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v182 = val1.post_place_retreat
        _v183 = _v182.direction
        _v184 = _v183.header
        _x = _v184.seq
        buff.write(_get_struct_I().pack(_x))
        _v185 = _v184.stamp
        _x = _v185
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v184.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v186 = _v183.vector
        _x = _v186
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v182
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
    except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
    except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))

  def deserialize_numpy(self, str, numpy):
    """
    unpack serialized message in str into this message instance using numpy for array types
    :param str: byte array of serialized message, ``str``
    :param numpy: numpy python module
    """
    codecs.lookup_error("rosmsg").msg_type = self._type
    try:
      if self.action_goal is None:
        self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      if self.action_result is None:
        self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      if self.action_feedback is None:
        self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()
      end = 0
      _x = self
      start = end
      end += 12
      (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal_id.id = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.header.frame_id = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.name = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.support_surface = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.support_surface = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.properties = []
      for i in range(0, length):
        val1 = grasping_msgs.msg.ObjectProperty()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.value = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.value = str[start:end]
        self.action_goal.goal.object.properties.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.fields = []
      for i in range(0, length):
        val1 = sensor_msgs.msg.PointField()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        _x = val1
        start = end
        end += 9
        (_x.offset, _x.datatype, _x.count,) = _get_struct_IBI().unpack(str[start:end])
        self.action_goal.goal.object.point_cluster.fields.append(val1)
      _x = self
      start = end
      end += 9
      (_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step,) = _get_struct_B2I().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_bigendian = bool(self.action_goal.goal.object.point_cluster.is_bigendian)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      self.action_goal.goal.object.point_cluster.data = str[start:end]
      start = end
      end += 1
      (self.action_goal.goal.object.point_cluster.is_dense,) = _get_struct_B().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_dense = bool(self.action_goal.goal.object.point_cluster.is_dense)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitives = []
      for i in range(0, length):
        val1 = shape_msgs.msg.SolidPrimitive()
        start = end
        end += 1
        (val1.type,) = _get_struct_B().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        pattern = '<%sd'%length
        start = end
        s = struct.Struct(pattern)
        end += s.size
        val1.dimensions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
        self.action_goal.goal.object.primitives.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitive_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v187 = val1.position
        _x = _v187
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v188 = val1.orientation
        _x = _v188
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.primitive_poses.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.meshes = []
      for i in range(0, length):
        val1 = shape_msgs.msg.Mesh()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.triangles = []
        for i in range(0, length):
          val2 = shape_msgs.msg.MeshTriangle()
          start = end
          end += 12
          val2.vertex_indices = numpy.frombuffer(str[start:end], dtype=numpy.uint32, count=3)
          val1.triangles.append(val2)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.vertices = []
        for i in range(0, length):
          val2 = geometry_msgs.msg.Point()
          _x = val2
          start = end
          end += 24
          (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
          val1.vertices.append(val2)
        self.action_goal.goal.object.meshes.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.mesh_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v189 = val1.position
        _x = _v189
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v190 = val1.orientation
        _x = _v190
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.mesh_poses.append(val1)
      start = end
      end += 32
      self.action_goal.goal.object.surface.coef = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=4)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.group_name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.group_name = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_result.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_result.result.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v191 = val1.pre_grasp_posture
        _v192 = _v191.header
        start = end
        end += 4
        (_v192.seq,) = _get_struct_I().unpack(str[start:end])
        _v193 = _v192.stamp
        _x = _v193
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v192.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v192.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v191.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v191.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v191.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v194 = val3.time_from_start
          _x = _v194
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v191.points.append(val3)
        _v195 = val1.grasp_posture
        _v196 = _v195.header
        start = end
        end += 4
        (_v196.seq,) = _get_struct_I().unpack(str[start:end])
        _v197 = _v196.stamp
        _x = _v197
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v196.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v196.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v195.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v195.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v195.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v198 = val3.time_from_start
          _x = _v198
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v195.points.append(val3)
        _v199 = val1.grasp_pose
        _v200 = _v199.header
        start = end
        end += 4
        (_v200.seq,) = _get_struct_I().unpack(str[start:end])
        _v201 = _v200.stamp
        _x = _v201
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v200.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v200.frame_id = str[start:end]
        _v202 = _v199.pose
        _v203 = _v202.position
        _x = _v203
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v204 = _v202.orientation
        _x = _v204
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v205 = val1.pre_grasp_approach
        _v206 = _v205.direction
        _v207 = _v206.header
        start = end
        end += 4
        (_v207.seq,) = _get_struct_I().unpack(str[start:end])
        _v208 = _v207.stamp
        _x = _v208
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v207.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v207.frame_id = str[start:end]
        _v209 = _v206.vector
        _x = _v209
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v205
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v210 = val1.post_grasp_retreat
        _v211 = _v210.direction
        _v212 = _v211.header
        start = end
        end += 4
        (_v212.seq,) = _get_struct_I().unpack(str[start:end])
        _v213 = _v212.stamp
        _x = _v213
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v212.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v212.frame_id = str[start:end]
        _v214 = _v211.vector
        _x = _v214
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v210
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v215 = val1.post_place_retreat
        _v216 = _v215.direction
        _v217 = _v216.header
        start = end
        end += 4
        (_v217.seq,) = _get_struct_I().unpack(str[start:end])
        _v218 = _v217.stamp
        _x = _v218
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v217.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v217.frame_id = str[start:end]
        _v219 = _v216.vector
        _x = _v219
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v215
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_result.result.grasps.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_feedback.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_feedback.feedback.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v220 = val1.pre_grasp_posture
        _v221 = _v220.header
        start = end
        end += 4
        (_v221.seq,) = _get_struct_I().unpack(str[start:end])
        _v222 = _v221.stamp
        _x = _v222
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v221.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v221.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v220.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v220.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v220.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v223 = val3.time_from_start
          _x = _v223
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v220.points.append(val3)
        _v224 = val1.grasp_posture
        _v225 = _v224.header
        start = end
        end += 4
        (_v225.seq,) = _get_struct_I().unpack(str[start:end])
        _v226 = _v225.stamp
        _x = _v226
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v225.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v225.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v224.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v224.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v224.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v227 = val3.time_from_start
          _x = _v227
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v224.points.append(val3)
        _v228 = val1.grasp_pose
        _v229 = _v228.header
        start = end
        end += 4
        (_v229.seq,) = _get_struct_I().unpack(str[start:end])
        _v230 = _v229.stamp
        _x = _v230
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v229.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v229.frame_id = str[start:end]
        _v231 = _v228.pose
        _v232 = _v231.position
        _x = _v232
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v233 = _v231.orientation
        _x = _v233
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v234 = val1.pre_grasp_approach
        _v235 = _v234.direction
        _v236 = _v235.header
        start = end
        end += 4
        (_v236.seq,) = _get_struct_I().unpack(str[start:end])
        _v237 = _v236.stamp
        _x = _v237
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v236.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v236.frame_id = str[start:end]
        _v238 = _v235.vector
        _x = _v238
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v234
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v239 = val1.post_grasp_retreat
        _v240 = _v239.direction
        _v241 = _v240.header
        start = end
        end += 4
        (_v241.seq,) = _get_struct_I().unpack(str[start:end])
        _v242 = _v241.stamp
        _x = _v242
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v241.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v241.frame_id = str[start:end]
        _v243 = _v240.vector
        _x = _v243
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v239
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v244 = val1.post_place_retreat
        _v245 = _v244.direction
        _v246 = _v245.header
        start = end
        end += 4
        (_v246.seq,) = _get_struct_I().unpack(str[start:end])
        _v247 = _v246.stamp
        _x = _v247
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v246.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v246.frame_id = str[start:end]
        _v248 = _v245.vector
        _x = _v248
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v244
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_feedback.feedback.grasps.append(val1)
      return self
    except struct.error as e:
      raise genpy.DeserializationError(e)  # most likely buffer underfill

_struct_I = genpy.struct_I
def _get_struct_I():
    global _struct_I
    return _struct_I
_struct_2I = None
def _get_struct_2I():
    global _struct_2I
    if _struct_2I is None:
        _struct_2I = struct.Struct("<2I")
    return _struct_2I
_struct_2f = None
def _get_struct_2f():
    global _struct_2f
    if _struct_2f is None:
        _struct_2f = struct.Struct("<2f")
    return _struct_2f
_struct_2i = None
def _get_struct_2i():
    global _struct_2i
    if _struct_2i is None:
        _struct_2i = struct.Struct("<2i")
    return _struct_2i
_struct_3I = None
def _get_struct_3I():
    global _struct_3I
    if _struct_3I is None:
        _struct_3I = struct.Struct("<3I")
    return _struct_3I
_struct_3d = None
def _get_struct_3d():
    global _struct_3d
    if _struct_3d is None:
        _struct_3d = struct.Struct("<3d")
    return _struct_3d
_struct_4d = None
def _get_struct_4d():
    global _struct_4d
    if _struct_4d is None:
        _struct_4d = struct.Struct("<4d")
    return _struct_4d
_struct_B = None
def _get_struct_B():
    global _struct_B
    if _struct_B is None:
        _struct_B = struct.Struct("<B")
    return _struct_B
_struct_B2I = None
def _get_struct_B2I():
    global _struct_B2I
    if _struct_B2I is None:
        _struct_B2I = struct.Struct("<B2I")
    return _struct_B2I
_struct_IBI = None
def _get_struct_IBI():
    global _struct_IBI
    if _struct_IBI is None:
        _struct_IBI = struct.Struct("<IBI")
    return _struct_IBI
_struct_d = None
def _get_struct_d():
    global _struct_d
    if _struct_d is None:
        _struct_d = struct.Struct("<d")
    return _struct_d
_struct_f = None
def _get_struct_f():
    global _struct_f
    if _struct_f is None:
        _struct_f = struct.Struct("<f")
    return _struct_f

# This Python file uses the following encoding: utf-8
"""autogenerated by genpy from grasping_msgs/GraspPlanningAction.msg. Do not edit."""
import codecs
import sys
python3 = True if sys.hexversion > 0x03000000 else False
import genpy
import struct

import actionlib_msgs.msg
import genpy
import geometry_msgs.msg
import grasping_msgs.msg
import moveit_msgs.msg
import sensor_msgs.msg
import shape_msgs.msg
import std_msgs.msg
import trajectory_msgs.msg

class GraspPlanningAction(genpy.Message):
  _md5sum = "7133eaf5c7bbf3f1f2b109ce543a58b0"
  _type = "grasping_msgs/GraspPlanningAction"
  _has_header = False  # flag to mark the presence of a Header object
  _full_text = """# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

GraspPlanningActionGoal action_goal
GraspPlanningActionResult action_result
GraspPlanningActionFeedback action_feedback

================================================================================
MSG: grasping_msgs/GraspPlanningActionGoal
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

Header header
actionlib_msgs/GoalID goal_id
GraspPlanningGoal goal

================================================================================
MSG: std_msgs/Header
# Standard metadata for higher-level stamped data types.
# This is generally used to communicate timestamped data 
# in a particular coordinate frame.
# 
# sequence ID: consecutively increasing ID 
uint32 seq
#Two-integer timestamp that is expressed as:
# * stamp.sec: seconds (stamp_secs) since epoch (in Python the variable is called 'secs')
# * stamp.nsec: nanoseconds since stamp_secs (in Python the variable is called 'nsecs')
# time-handling sugar is provided by the client library
time stamp
#Frame this data is associated with
string frame_id

================================================================================
MSG: actionlib_msgs/GoalID
# The stamp should store the time at which this goal was requested.
# It is used by an action server when it tries to preempt all
# goals that were requested before a certain time
time stamp

# The id provides a way to associate feedback and
# result message with specific goal requests. The id
# specified must be unique.
string id


================================================================================
MSG: grasping_msgs/GraspPlanningGoal
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
###########################################################
# This action is used when planning grasps for a single,
#  already known object, one object at a time.

# Object for which grasp planning is requested
Object object

# Name of group to plan with (optional)
string group_name

================================================================================
MSG: grasping_msgs/Object
###########################################################
# This message describes an object.

# Many of the geometric items below lack a stamp/frame_id,
# header stamp/frame_id should be used there
std_msgs/Header header

# An object might have a name
string name

# An object might have a known (named) support surface
string support_surface

# Objects might have properties, such as type/class, or color, etc.
ObjectProperty[] properties

###########################################################
# Objects have many possible descriptions
#  The following are the possible description formats

# Perception modules often represent an object as a cluster of points
#  Is considered valid if number of points > 0
sensor_msgs/PointCloud2 point_cluster

# MoveIt prefers solid primitives or meshes as a description of objects
shape_msgs/SolidPrimitive[] primitives
geometry_msgs/Pose[] primitive_poses

shape_msgs/Mesh[] meshes
geometry_msgs/Pose[] mesh_poses

# An object representing a support surface might be described by a plane
# Is considered valid if coefficients are not all 0s.
shape_msgs/Plane surface

================================================================================
MSG: grasping_msgs/ObjectProperty
###########################################################
# Other generic properties of an object
string name
string value

================================================================================
MSG: sensor_msgs/PointCloud2
# This message holds a collection of N-dimensional points, which may
# contain additional information such as normals, intensity, etc. The
# point data is stored as a binary blob, its layout described by the
# contents of the "fields" array.

# The point cloud data may be organized 2d (image-like) or 1d
# (unordered). Point clouds organized as 2d images may be produced by
# camera depth sensors such as stereo or time-of-flight.

# Time of sensor data acquisition, and the coordinate frame ID (for 3d
# points).
Header header

# 2D structure of the point cloud. If the cloud is unordered, height is
# 1 and width is the length of the point cloud.
uint32 height
uint32 width

# Describes the channels and their layout in the binary data blob.
PointField[] fields

bool    is_bigendian # Is this data bigendian?
uint32  point_step   # Length of a point in bytes
uint32  row_step     # Length of a row in bytes
uint8[] data         # Actual point data, size is (row_step*height)

bool is_dense        # True if there are no invalid points

================================================================================
MSG: sensor_msgs/PointField
# This message holds the description of one point entry in the
# PointCloud2 message format.
uint8 INT8    = 1
uint8 UINT8   = 2
uint8 INT16   = 3
uint8 UINT16  = 4
uint8 INT32   = 5
uint8 UINT32  = 6
uint8 FLOAT32 = 7
uint8 FLOAT64 = 8

string name      # Name of field
uint32 offset    # Offset from start of point struct
uint8  datatype  # Datatype enumeration, see above
uint32 count     # How many elements in the field

================================================================================
MSG: shape_msgs/SolidPrimitive
# Define box, sphere, cylinder, cone 
# All shapes are defined to have their bounding boxes centered around 0,0,0.

uint8 BOX=1
uint8 SPHERE=2
uint8 CYLINDER=3
uint8 CONE=4

# The type of the shape
uint8 type


# The dimensions of the shape
float64[] dimensions

# The meaning of the shape dimensions: each constant defines the index in the 'dimensions' array

# For the BOX type, the X, Y, and Z dimensions are the length of the corresponding
# sides of the box.
uint8 BOX_X=0
uint8 BOX_Y=1
uint8 BOX_Z=2


# For the SPHERE type, only one component is used, and it gives the radius of
# the sphere.
uint8 SPHERE_RADIUS=0


# For the CYLINDER and CONE types, the center line is oriented along
# the Z axis.  Therefore the CYLINDER_HEIGHT (CONE_HEIGHT) component
# of dimensions gives the height of the cylinder (cone).  The
# CYLINDER_RADIUS (CONE_RADIUS) component of dimensions gives the
# radius of the base of the cylinder (cone).  Cone and cylinder
# primitives are defined to be circular. The tip of the cone is
# pointing up, along +Z axis.

uint8 CYLINDER_HEIGHT=0
uint8 CYLINDER_RADIUS=1

uint8 CONE_HEIGHT=0
uint8 CONE_RADIUS=1

================================================================================
MSG: geometry_msgs/Pose
# A representation of pose in free space, composed of position and orientation. 
Point position
Quaternion orientation

================================================================================
MSG: geometry_msgs/Point
# This contains the position of a point in free space
float64 x
float64 y
float64 z

================================================================================
MSG: geometry_msgs/Quaternion
# This represents an orientation in free space in quaternion form.

float64 x
float64 y
float64 z
float64 w

================================================================================
MSG: shape_msgs/Mesh
# Definition of a mesh

# list of triangles; the index values refer to positions in vertices[]
MeshTriangle[] triangles

# the actual vertices that make up the mesh
geometry_msgs/Point[] vertices

================================================================================
MSG: shape_msgs/MeshTriangle
# Definition of a triangle's vertices
uint32[3] vertex_indices

================================================================================
MSG: shape_msgs/Plane
# Representation of a plane, using the plane equation ax + by + cz + d = 0

# a := coef[0]
# b := coef[1]
# c := coef[2]
# d := coef[3]

float64[4] coef

================================================================================
MSG: grasping_msgs/GraspPlanningActionResult
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

Header header
actionlib_msgs/GoalStatus status
GraspPlanningResult result

================================================================================
MSG: actionlib_msgs/GoalStatus
GoalID goal_id
uint8 status
uint8 PENDING         = 0   # The goal has yet to be processed by the action server
uint8 ACTIVE          = 1   # The goal is currently being processed by the action server
uint8 PREEMPTED       = 2   # The goal received a cancel request after it started executing
                            #   and has since completed its execution (Terminal State)
uint8 SUCCEEDED       = 3   # The goal was achieved successfully by the action server (Terminal State)
uint8 ABORTED         = 4   # The goal was aborted during execution by the action server due
                            #    to some failure (Terminal State)
uint8 REJECTED        = 5   # The goal was rejected by the action server without being processed,
                            #    because the goal was unattainable or invalid (Terminal State)
uint8 PREEMPTING      = 6   # The goal received a cancel request after it started executing
                            #    and has not yet completed execution
uint8 RECALLING       = 7   # The goal received a cancel request before it started executing,
                            #    but the action server has not yet confirmed that the goal is canceled
uint8 RECALLED        = 8   # The goal received a cancel request before it started executing
                            #    and was successfully cancelled (Terminal State)
uint8 LOST            = 9   # An action client can determine that a goal is LOST. This should not be
                            #    sent over the wire by an action server

#Allow for the user to associate a string with GoalStatus for debugging
string text


================================================================================
MSG: grasping_msgs/GraspPlanningResult
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
# All grasps
moveit_msgs/Grasp[] grasps

================================================================================
MSG: moveit_msgs/Grasp
# This message contains a description of a grasp that would be used
# with a particular end-effector to grasp an object, including how to
# approach it, grip it, etc.  This message does not contain any
# information about a "grasp point" (a position ON the object).
# Whatever generates this message should have already combined
# information about grasp points with information about the geometry
# of the end-effector to compute the grasp_pose in this message.

# A name for this grasp
string id

# The internal posture of the hand for the pre-grasp
# only positions are used
trajectory_msgs/JointTrajectory pre_grasp_posture

# The internal posture of the hand for the grasp
# positions and efforts are used
trajectory_msgs/JointTrajectory grasp_posture

# The position of the end-effector for the grasp.  This is the pose of
# the "parent_link" of the end-effector, not actually the pose of any
# link *in* the end-effector.  Typically this would be the pose of the
# most distal wrist link before the hand (end-effector) links began.
geometry_msgs/PoseStamped grasp_pose

# The estimated probability of success for this grasp, or some other
# measure of how "good" it is.
float64 grasp_quality

# The approach direction to take before picking an object
GripperTranslation pre_grasp_approach

# The retreat direction to take after a grasp has been completed (object is attached)
GripperTranslation post_grasp_retreat

# The retreat motion to perform when releasing the object; this information
# is not necessary for the grasp itself, but when releasing the object,
# the information will be necessary. The grasp used to perform a pickup
# is returned as part of the result, so this information is available for 
# later use.
GripperTranslation post_place_retreat

# the maximum contact force to use while grasping (<=0 to disable)
float32 max_contact_force

# an optional list of obstacles that we have semantic information about
# and that can be touched/pushed/moved in the course of grasping
string[] allowed_touch_objects

================================================================================
MSG: trajectory_msgs/JointTrajectory
Header header
string[] joint_names
JointTrajectoryPoint[] points

================================================================================
MSG: trajectory_msgs/JointTrajectoryPoint
# Each trajectory point specifies either positions[, velocities[, accelerations]]
# or positions[, effort] for the trajectory to be executed.
# All specified values are in the same order as the joint names in JointTrajectory.msg

float64[] positions
float64[] velocities
float64[] accelerations
float64[] effort
duration time_from_start

================================================================================
MSG: geometry_msgs/PoseStamped
# A Pose with reference coordinate frame and timestamp
Header header
Pose pose

================================================================================
MSG: moveit_msgs/GripperTranslation
# defines a translation for the gripper, used in pickup or place tasks
# for example for lifting an object off a table or approaching the table for placing

# the direction of the translation
geometry_msgs/Vector3Stamped direction

# the desired translation distance
float32 desired_distance

# the min distance that must be considered feasible before the
# grasp is even attempted
float32 min_distance

================================================================================
MSG: geometry_msgs/Vector3Stamped
# This represents a Vector3 with reference coordinate frame and timestamp
Header header
Vector3 vector

================================================================================
MSG: geometry_msgs/Vector3
# This represents a vector in free space. 
# It is only meant to represent a direction. Therefore, it does not
# make sense to apply a translation to it (e.g., when applying a 
# generic rigid transformation to a Vector3, tf2 will only apply the
# rotation). If you want your data to be translatable too, use the
# geometry_msgs/Point message instead.

float64 x
float64 y
float64 z
================================================================================
MSG: grasping_msgs/GraspPlanningActionFeedback
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======

Header header
actionlib_msgs/GoalStatus status
GraspPlanningFeedback feedback

================================================================================
MSG: grasping_msgs/GraspPlanningFeedback
# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======
# Grasps found thus far
moveit_msgs/Grasp[] grasps

"""
  __slots__ = ['action_goal','action_result','action_feedback']
  _slot_types = ['grasping_msgs/GraspPlanningActionGoal','grasping_msgs/GraspPlanningActionResult','grasping_msgs/GraspPlanningActionFeedback']

  def __init__(self, *args, **kwds):
    """
    Constructor. Any message fields that are implicitly/explicitly
    set to None will be assigned a default value. The recommend
    use is keyword arguments as this is more robust to future message
    changes.  You cannot mix in-order arguments and keyword arguments.

    The available fields are:
       action_goal,action_result,action_feedback

    :param args: complete set of field values, in .msg order
    :param kwds: use keyword arguments corresponding to message field names
    to set specific fields.
    """
    if args or kwds:
      super(GraspPlanningAction, self).__init__(*args, **kwds)
      # message fields cannot be None, assign default values for those that are
      if self.action_goal is None:
        self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      if self.action_result is None:
        self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      if self.action_feedback is None:
        self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()
    else:
      self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()

  def _get_types(self):
    """
    internal API method
    """
    return self._slot_types

  def serialize(self, buff):
    """
    serialize message into buffer
    :param buff: buffer, ``StringIO``
    """
    try:
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
      _x = self.action_goal.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
      _x = self.action_goal.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs))
      _x = self.action_goal.goal.object.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.support_surface
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_goal.goal.object.properties)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.properties:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1.value
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs))
      _x = self.action_goal.goal.object.point_cluster.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width))
      length = len(self.action_goal.goal.object.point_cluster.fields)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.point_cluster.fields:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1
        buff.write(_get_struct_IBI().pack(_x.offset, _x.datatype, _x.count))
      _x = self
      buff.write(_get_struct_B2I().pack(_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step))
      _x = self.action_goal.goal.object.point_cluster.data
      length = len(_x)
      # - if encoded as a list instead, serialize as bytes instead of string
      if type(_x) in [list, tuple]:
        buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
      else:
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.point_cluster.is_dense
      buff.write(_get_struct_B().pack(_x))
      length = len(self.action_goal.goal.object.primitives)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitives:
        _x = val1.type
        buff.write(_get_struct_B().pack(_x))
        length = len(val1.dimensions)
        buff.write(_struct_I.pack(length))
        pattern = '<%sd'%length
        buff.write(struct.Struct(pattern).pack(*val1.dimensions))
      length = len(self.action_goal.goal.object.primitive_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitive_poses:
        _v1 = val1.position
        _x = _v1
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v2 = val1.orientation
        _x = _v2
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      length = len(self.action_goal.goal.object.meshes)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.meshes:
        length = len(val1.triangles)
        buff.write(_struct_I.pack(length))
        for val2 in val1.triangles:
          buff.write(_get_struct_3I().pack(*val2.vertex_indices))
        length = len(val1.vertices)
        buff.write(_struct_I.pack(length))
        for val2 in val1.vertices:
          _x = val2
          buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
      length = len(self.action_goal.goal.object.mesh_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.mesh_poses:
        _v3 = val1.position
        _x = _v3
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v4 = val1.orientation
        _x = _v4
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      buff.write(_get_struct_4d().pack(*self.action_goal.goal.object.surface.coef))
      _x = self.action_goal.goal.group_name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
      _x = self.action_result.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
      _x = self.action_result.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_result.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_result.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_result.result.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_result.result.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v5 = val1.pre_grasp_posture
        _v6 = _v5.header
        _x = _v6.seq
        buff.write(_get_struct_I().pack(_x))
        _v7 = _v6.stamp
        _x = _v7
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v6.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v5.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v5.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v5.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v5.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v8 = val3.time_from_start
          _x = _v8
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v9 = val1.grasp_posture
        _v10 = _v9.header
        _x = _v10.seq
        buff.write(_get_struct_I().pack(_x))
        _v11 = _v10.stamp
        _x = _v11
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v10.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v9.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v9.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v9.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v9.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v12 = val3.time_from_start
          _x = _v12
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v13 = val1.grasp_pose
        _v14 = _v13.header
        _x = _v14.seq
        buff.write(_get_struct_I().pack(_x))
        _v15 = _v14.stamp
        _x = _v15
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v14.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v16 = _v13.pose
        _v17 = _v16.position
        _x = _v17
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v18 = _v16.orientation
        _x = _v18
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v19 = val1.pre_grasp_approach
        _v20 = _v19.direction
        _v21 = _v20.header
        _x = _v21.seq
        buff.write(_get_struct_I().pack(_x))
        _v22 = _v21.stamp
        _x = _v22
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v21.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v23 = _v20.vector
        _x = _v23
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v19
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v24 = val1.post_grasp_retreat
        _v25 = _v24.direction
        _v26 = _v25.header
        _x = _v26.seq
        buff.write(_get_struct_I().pack(_x))
        _v27 = _v26.stamp
        _x = _v27
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v26.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v28 = _v25.vector
        _x = _v28
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v24
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v29 = val1.post_place_retreat
        _v30 = _v29.direction
        _v31 = _v30.header
        _x = _v31.seq
        buff.write(_get_struct_I().pack(_x))
        _v32 = _v31.stamp
        _x = _v32
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v31.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v33 = _v30.vector
        _x = _v33
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v29
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
      _x = self.action_feedback.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
      _x = self.action_feedback.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_feedback.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_feedback.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_feedback.feedback.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_feedback.feedback.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v34 = val1.pre_grasp_posture
        _v35 = _v34.header
        _x = _v35.seq
        buff.write(_get_struct_I().pack(_x))
        _v36 = _v35.stamp
        _x = _v36
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v35.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v34.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v34.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v34.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v34.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v37 = val3.time_from_start
          _x = _v37
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v38 = val1.grasp_posture
        _v39 = _v38.header
        _x = _v39.seq
        buff.write(_get_struct_I().pack(_x))
        _v40 = _v39.stamp
        _x = _v40
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v39.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v38.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v38.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v38.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v38.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.positions))
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.velocities))
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.accelerations))
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(struct.Struct(pattern).pack(*val3.effort))
          _v41 = val3.time_from_start
          _x = _v41
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v42 = val1.grasp_pose
        _v43 = _v42.header
        _x = _v43.seq
        buff.write(_get_struct_I().pack(_x))
        _v44 = _v43.stamp
        _x = _v44
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v43.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v45 = _v42.pose
        _v46 = _v45.position
        _x = _v46
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v47 = _v45.orientation
        _x = _v47
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v48 = val1.pre_grasp_approach
        _v49 = _v48.direction
        _v50 = _v49.header
        _x = _v50.seq
        buff.write(_get_struct_I().pack(_x))
        _v51 = _v50.stamp
        _x = _v51
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v50.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v52 = _v49.vector
        _x = _v52
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v48
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v53 = val1.post_grasp_retreat
        _v54 = _v53.direction
        _v55 = _v54.header
        _x = _v55.seq
        buff.write(_get_struct_I().pack(_x))
        _v56 = _v55.stamp
        _x = _v56
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v55.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v57 = _v54.vector
        _x = _v57
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v53
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v58 = val1.post_place_retreat
        _v59 = _v58.direction
        _v60 = _v59.header
        _x = _v60.seq
        buff.write(_get_struct_I().pack(_x))
        _v61 = _v60.stamp
        _x = _v61
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v60.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v62 = _v59.vector
        _x = _v62
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v58
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
    except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
    except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))

  def deserialize(self, str):
    """
    unpack serialized message in str into this message instance
    :param str: byte array of serialized message, ``str``
    """
    codecs.lookup_error("rosmsg").msg_type = self._type
    try:
      if self.action_goal is None:
        self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      if self.action_result is None:
        self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      if self.action_feedback is None:
        self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()
      end = 0
      _x = self
      start = end
      end += 12
      (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal_id.id = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.header.frame_id = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.name = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.support_surface = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.support_surface = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.properties = []
      for i in range(0, length):
        val1 = grasping_msgs.msg.ObjectProperty()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.value = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.value = str[start:end]
        self.action_goal.goal.object.properties.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.fields = []
      for i in range(0, length):
        val1 = sensor_msgs.msg.PointField()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        _x = val1
        start = end
        end += 9
        (_x.offset, _x.datatype, _x.count,) = _get_struct_IBI().unpack(str[start:end])
        self.action_goal.goal.object.point_cluster.fields.append(val1)
      _x = self
      start = end
      end += 9
      (_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step,) = _get_struct_B2I().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_bigendian = bool(self.action_goal.goal.object.point_cluster.is_bigendian)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      self.action_goal.goal.object.point_cluster.data = str[start:end]
      start = end
      end += 1
      (self.action_goal.goal.object.point_cluster.is_dense,) = _get_struct_B().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_dense = bool(self.action_goal.goal.object.point_cluster.is_dense)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitives = []
      for i in range(0, length):
        val1 = shape_msgs.msg.SolidPrimitive()
        start = end
        end += 1
        (val1.type,) = _get_struct_B().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        pattern = '<%sd'%length
        start = end
        s = struct.Struct(pattern)
        end += s.size
        val1.dimensions = s.unpack(str[start:end])
        self.action_goal.goal.object.primitives.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitive_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v63 = val1.position
        _x = _v63
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v64 = val1.orientation
        _x = _v64
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.primitive_poses.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.meshes = []
      for i in range(0, length):
        val1 = shape_msgs.msg.Mesh()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.triangles = []
        for i in range(0, length):
          val2 = shape_msgs.msg.MeshTriangle()
          start = end
          end += 12
          val2.vertex_indices = _get_struct_3I().unpack(str[start:end])
          val1.triangles.append(val2)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.vertices = []
        for i in range(0, length):
          val2 = geometry_msgs.msg.Point()
          _x = val2
          start = end
          end += 24
          (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
          val1.vertices.append(val2)
        self.action_goal.goal.object.meshes.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.mesh_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v65 = val1.position
        _x = _v65
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v66 = val1.orientation
        _x = _v66
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.mesh_poses.append(val1)
      start = end
      end += 32
      self.action_goal.goal.object.surface.coef = _get_struct_4d().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.group_name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.group_name = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_result.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_result.result.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v67 = val1.pre_grasp_posture
        _v68 = _v67.header
        start = end
        end += 4
        (_v68.seq,) = _get_struct_I().unpack(str[start:end])
        _v69 = _v68.stamp
        _x = _v69
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v68.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v68.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v67.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v67.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v67.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v70 = val3.time_from_start
          _x = _v70
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v67.points.append(val3)
        _v71 = val1.grasp_posture
        _v72 = _v71.header
        start = end
        end += 4
        (_v72.seq,) = _get_struct_I().unpack(str[start:end])
        _v73 = _v72.stamp
        _x = _v73
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v72.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v72.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v71.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v71.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v71.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v74 = val3.time_from_start
          _x = _v74
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v71.points.append(val3)
        _v75 = val1.grasp_pose
        _v76 = _v75.header
        start = end
        end += 4
        (_v76.seq,) = _get_struct_I().unpack(str[start:end])
        _v77 = _v76.stamp
        _x = _v77
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v76.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v76.frame_id = str[start:end]
        _v78 = _v75.pose
        _v79 = _v78.position
        _x = _v79
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v80 = _v78.orientation
        _x = _v80
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v81 = val1.pre_grasp_approach
        _v82 = _v81.direction
        _v83 = _v82.header
        start = end
        end += 4
        (_v83.seq,) = _get_struct_I().unpack(str[start:end])
        _v84 = _v83.stamp
        _x = _v84
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v83.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v83.frame_id = str[start:end]
        _v85 = _v82.vector
        _x = _v85
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v81
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v86 = val1.post_grasp_retreat
        _v87 = _v86.direction
        _v88 = _v87.header
        start = end
        end += 4
        (_v88.seq,) = _get_struct_I().unpack(str[start:end])
        _v89 = _v88.stamp
        _x = _v89
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v88.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v88.frame_id = str[start:end]
        _v90 = _v87.vector
        _x = _v90
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v86
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v91 = val1.post_place_retreat
        _v92 = _v91.direction
        _v93 = _v92.header
        start = end
        end += 4
        (_v93.seq,) = _get_struct_I().unpack(str[start:end])
        _v94 = _v93.stamp
        _x = _v94
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v93.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v93.frame_id = str[start:end]
        _v95 = _v92.vector
        _x = _v95
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v91
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_result.result.grasps.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_feedback.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_feedback.feedback.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v96 = val1.pre_grasp_posture
        _v97 = _v96.header
        start = end
        end += 4
        (_v97.seq,) = _get_struct_I().unpack(str[start:end])
        _v98 = _v97.stamp
        _x = _v98
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v97.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v97.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v96.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v96.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v96.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v99 = val3.time_from_start
          _x = _v99
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v96.points.append(val3)
        _v100 = val1.grasp_posture
        _v101 = _v100.header
        start = end
        end += 4
        (_v101.seq,) = _get_struct_I().unpack(str[start:end])
        _v102 = _v101.stamp
        _x = _v102
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v101.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v101.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v100.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v100.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v100.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = s.unpack(str[start:end])
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = s.unpack(str[start:end])
          _v103 = val3.time_from_start
          _x = _v103
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v100.points.append(val3)
        _v104 = val1.grasp_pose
        _v105 = _v104.header
        start = end
        end += 4
        (_v105.seq,) = _get_struct_I().unpack(str[start:end])
        _v106 = _v105.stamp
        _x = _v106
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v105.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v105.frame_id = str[start:end]
        _v107 = _v104.pose
        _v108 = _v107.position
        _x = _v108
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v109 = _v107.orientation
        _x = _v109
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v110 = val1.pre_grasp_approach
        _v111 = _v110.direction
        _v112 = _v111.header
        start = end
        end += 4
        (_v112.seq,) = _get_struct_I().unpack(str[start:end])
        _v113 = _v112.stamp
        _x = _v113
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v112.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v112.frame_id = str[start:end]
        _v114 = _v111.vector
        _x = _v114
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v110
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v115 = val1.post_grasp_retreat
        _v116 = _v115.direction
        _v117 = _v116.header
        start = end
        end += 4
        (_v117.seq,) = _get_struct_I().unpack(str[start:end])
        _v118 = _v117.stamp
        _x = _v118
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v117.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v117.frame_id = str[start:end]
        _v119 = _v116.vector
        _x = _v119
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v115
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v120 = val1.post_place_retreat
        _v121 = _v120.direction
        _v122 = _v121.header
        start = end
        end += 4
        (_v122.seq,) = _get_struct_I().unpack(str[start:end])
        _v123 = _v122.stamp
        _x = _v123
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v122.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v122.frame_id = str[start:end]
        _v124 = _v121.vector
        _x = _v124
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v120
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_feedback.feedback.grasps.append(val1)
      return self
    except struct.error as e:
      raise genpy.DeserializationError(e)  # most likely buffer underfill


  def serialize_numpy(self, buff, numpy):
    """
    serialize message with numpy array types into buffer
    :param buff: buffer, ``StringIO``
    :param numpy: numpy python module
    """
    try:
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs))
      _x = self.action_goal.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs))
      _x = self.action_goal.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs))
      _x = self.action_goal.goal.object.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.support_surface
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_goal.goal.object.properties)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.properties:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1.value
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs))
      _x = self.action_goal.goal.object.point_cluster.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width))
      length = len(self.action_goal.goal.object.point_cluster.fields)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.point_cluster.fields:
        _x = val1.name
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _x = val1
        buff.write(_get_struct_IBI().pack(_x.offset, _x.datatype, _x.count))
      _x = self
      buff.write(_get_struct_B2I().pack(_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step))
      _x = self.action_goal.goal.object.point_cluster.data
      length = len(_x)
      # - if encoded as a list instead, serialize as bytes instead of string
      if type(_x) in [list, tuple]:
        buff.write(struct.Struct('<I%sB'%length).pack(length, *_x))
      else:
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_goal.goal.object.point_cluster.is_dense
      buff.write(_get_struct_B().pack(_x))
      length = len(self.action_goal.goal.object.primitives)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitives:
        _x = val1.type
        buff.write(_get_struct_B().pack(_x))
        length = len(val1.dimensions)
        buff.write(_struct_I.pack(length))
        pattern = '<%sd'%length
        buff.write(val1.dimensions.tostring())
      length = len(self.action_goal.goal.object.primitive_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.primitive_poses:
        _v125 = val1.position
        _x = _v125
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v126 = val1.orientation
        _x = _v126
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      length = len(self.action_goal.goal.object.meshes)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.meshes:
        length = len(val1.triangles)
        buff.write(_struct_I.pack(length))
        for val2 in val1.triangles:
          buff.write(val2.vertex_indices.tostring())
        length = len(val1.vertices)
        buff.write(_struct_I.pack(length))
        for val2 in val1.vertices:
          _x = val2
          buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
      length = len(self.action_goal.goal.object.mesh_poses)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_goal.goal.object.mesh_poses:
        _v127 = val1.position
        _x = _v127
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v128 = val1.orientation
        _x = _v128
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
      buff.write(self.action_goal.goal.object.surface.coef.tostring())
      _x = self.action_goal.goal.group_name
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs))
      _x = self.action_result.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs))
      _x = self.action_result.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_result.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_result.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_result.result.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_result.result.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v129 = val1.pre_grasp_posture
        _v130 = _v129.header
        _x = _v130.seq
        buff.write(_get_struct_I().pack(_x))
        _v131 = _v130.stamp
        _x = _v131
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v130.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v129.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v129.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v129.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v129.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v132 = val3.time_from_start
          _x = _v132
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v133 = val1.grasp_posture
        _v134 = _v133.header
        _x = _v134.seq
        buff.write(_get_struct_I().pack(_x))
        _v135 = _v134.stamp
        _x = _v135
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v134.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v133.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v133.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v133.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v133.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v136 = val3.time_from_start
          _x = _v136
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v137 = val1.grasp_pose
        _v138 = _v137.header
        _x = _v138.seq
        buff.write(_get_struct_I().pack(_x))
        _v139 = _v138.stamp
        _x = _v139
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v138.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v140 = _v137.pose
        _v141 = _v140.position
        _x = _v141
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v142 = _v140.orientation
        _x = _v142
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v143 = val1.pre_grasp_approach
        _v144 = _v143.direction
        _v145 = _v144.header
        _x = _v145.seq
        buff.write(_get_struct_I().pack(_x))
        _v146 = _v145.stamp
        _x = _v146
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v145.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v147 = _v144.vector
        _x = _v147
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v143
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v148 = val1.post_grasp_retreat
        _v149 = _v148.direction
        _v150 = _v149.header
        _x = _v150.seq
        buff.write(_get_struct_I().pack(_x))
        _v151 = _v150.stamp
        _x = _v151
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v150.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v152 = _v149.vector
        _x = _v152
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v148
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v153 = val1.post_place_retreat
        _v154 = _v153.direction
        _v155 = _v154.header
        _x = _v155.seq
        buff.write(_get_struct_I().pack(_x))
        _v156 = _v155.stamp
        _x = _v156
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v155.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v157 = _v154.vector
        _x = _v157
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v153
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
      _x = self
      buff.write(_get_struct_3I().pack(_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs))
      _x = self.action_feedback.header.frame_id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self
      buff.write(_get_struct_2I().pack(_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs))
      _x = self.action_feedback.status.goal_id.id
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      _x = self.action_feedback.status.status
      buff.write(_get_struct_B().pack(_x))
      _x = self.action_feedback.status.text
      length = len(_x)
      if python3 or type(_x) == unicode:
        _x = _x.encode('utf-8')
        length = len(_x)
      buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
      length = len(self.action_feedback.feedback.grasps)
      buff.write(_struct_I.pack(length))
      for val1 in self.action_feedback.feedback.grasps:
        _x = val1.id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v158 = val1.pre_grasp_posture
        _v159 = _v158.header
        _x = _v159.seq
        buff.write(_get_struct_I().pack(_x))
        _v160 = _v159.stamp
        _x = _v160
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v159.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v158.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v158.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v158.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v158.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v161 = val3.time_from_start
          _x = _v161
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v162 = val1.grasp_posture
        _v163 = _v162.header
        _x = _v163.seq
        buff.write(_get_struct_I().pack(_x))
        _v164 = _v163.stamp
        _x = _v164
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v163.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        length = len(_v162.joint_names)
        buff.write(_struct_I.pack(length))
        for val3 in _v162.joint_names:
          length = len(val3)
          if python3 or type(val3) == unicode:
            val3 = val3.encode('utf-8')
            length = len(val3)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val3))
        length = len(_v162.points)
        buff.write(_struct_I.pack(length))
        for val3 in _v162.points:
          length = len(val3.positions)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.positions.tostring())
          length = len(val3.velocities)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.velocities.tostring())
          length = len(val3.accelerations)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.accelerations.tostring())
          length = len(val3.effort)
          buff.write(_struct_I.pack(length))
          pattern = '<%sd'%length
          buff.write(val3.effort.tostring())
          _v165 = val3.time_from_start
          _x = _v165
          buff.write(_get_struct_2i().pack(_x.secs, _x.nsecs))
        _v166 = val1.grasp_pose
        _v167 = _v166.header
        _x = _v167.seq
        buff.write(_get_struct_I().pack(_x))
        _v168 = _v167.stamp
        _x = _v168
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v167.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v169 = _v166.pose
        _v170 = _v169.position
        _x = _v170
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _v171 = _v169.orientation
        _x = _v171
        buff.write(_get_struct_4d().pack(_x.x, _x.y, _x.z, _x.w))
        _x = val1.grasp_quality
        buff.write(_get_struct_d().pack(_x))
        _v172 = val1.pre_grasp_approach
        _v173 = _v172.direction
        _v174 = _v173.header
        _x = _v174.seq
        buff.write(_get_struct_I().pack(_x))
        _v175 = _v174.stamp
        _x = _v175
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v174.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v176 = _v173.vector
        _x = _v176
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v172
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v177 = val1.post_grasp_retreat
        _v178 = _v177.direction
        _v179 = _v178.header
        _x = _v179.seq
        buff.write(_get_struct_I().pack(_x))
        _v180 = _v179.stamp
        _x = _v180
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v179.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v181 = _v178.vector
        _x = _v181
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v177
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _v182 = val1.post_place_retreat
        _v183 = _v182.direction
        _v184 = _v183.header
        _x = _v184.seq
        buff.write(_get_struct_I().pack(_x))
        _v185 = _v184.stamp
        _x = _v185
        buff.write(_get_struct_2I().pack(_x.secs, _x.nsecs))
        _x = _v184.frame_id
        length = len(_x)
        if python3 or type(_x) == unicode:
          _x = _x.encode('utf-8')
          length = len(_x)
        buff.write(struct.Struct('<I%ss'%length).pack(length, _x))
        _v186 = _v183.vector
        _x = _v186
        buff.write(_get_struct_3d().pack(_x.x, _x.y, _x.z))
        _x = _v182
        buff.write(_get_struct_2f().pack(_x.desired_distance, _x.min_distance))
        _x = val1.max_contact_force
        buff.write(_get_struct_f().pack(_x))
        length = len(val1.allowed_touch_objects)
        buff.write(_struct_I.pack(length))
        for val2 in val1.allowed_touch_objects:
          length = len(val2)
          if python3 or type(val2) == unicode:
            val2 = val2.encode('utf-8')
            length = len(val2)
          buff.write(struct.Struct('<I%ss'%length).pack(length, val2))
    except struct.error as se: self._check_types(struct.error("%s: '%s' when writing '%s'" % (type(se), str(se), str(locals().get('_x', self)))))
    except TypeError as te: self._check_types(ValueError("%s: '%s' when writing '%s'" % (type(te), str(te), str(locals().get('_x', self)))))

  def deserialize_numpy(self, str, numpy):
    """
    unpack serialized message in str into this message instance using numpy for array types
    :param str: byte array of serialized message, ``str``
    :param numpy: numpy python module
    """
    codecs.lookup_error("rosmsg").msg_type = self._type
    try:
      if self.action_goal is None:
        self.action_goal = grasping_msgs.msg.GraspPlanningActionGoal()
      if self.action_result is None:
        self.action_result = grasping_msgs.msg.GraspPlanningActionResult()
      if self.action_feedback is None:
        self.action_feedback = grasping_msgs.msg.GraspPlanningActionFeedback()
      end = 0
      _x = self
      start = end
      end += 12
      (_x.action_goal.header.seq, _x.action_goal.header.stamp.secs, _x.action_goal.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal_id.stamp.secs, _x.action_goal.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal_id.id = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.header.seq, _x.action_goal.goal.object.header.stamp.secs, _x.action_goal.goal.object.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.header.frame_id = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.name = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.support_surface = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.support_surface = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.properties = []
      for i in range(0, length):
        val1 = grasping_msgs.msg.ObjectProperty()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.value = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.value = str[start:end]
        self.action_goal.goal.object.properties.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_goal.goal.object.point_cluster.header.seq, _x.action_goal.goal.object.point_cluster.header.stamp.secs, _x.action_goal.goal.object.point_cluster.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.object.point_cluster.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_goal.goal.object.point_cluster.height, _x.action_goal.goal.object.point_cluster.width,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.fields = []
      for i in range(0, length):
        val1 = sensor_msgs.msg.PointField()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.name = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.name = str[start:end]
        _x = val1
        start = end
        end += 9
        (_x.offset, _x.datatype, _x.count,) = _get_struct_IBI().unpack(str[start:end])
        self.action_goal.goal.object.point_cluster.fields.append(val1)
      _x = self
      start = end
      end += 9
      (_x.action_goal.goal.object.point_cluster.is_bigendian, _x.action_goal.goal.object.point_cluster.point_step, _x.action_goal.goal.object.point_cluster.row_step,) = _get_struct_B2I().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_bigendian = bool(self.action_goal.goal.object.point_cluster.is_bigendian)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      self.action_goal.goal.object.point_cluster.data = str[start:end]
      start = end
      end += 1
      (self.action_goal.goal.object.point_cluster.is_dense,) = _get_struct_B().unpack(str[start:end])
      self.action_goal.goal.object.point_cluster.is_dense = bool(self.action_goal.goal.object.point_cluster.is_dense)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitives = []
      for i in range(0, length):
        val1 = shape_msgs.msg.SolidPrimitive()
        start = end
        end += 1
        (val1.type,) = _get_struct_B().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        pattern = '<%sd'%length
        start = end
        s = struct.Struct(pattern)
        end += s.size
        val1.dimensions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
        self.action_goal.goal.object.primitives.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.primitive_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v187 = val1.position
        _x = _v187
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v188 = val1.orientation
        _x = _v188
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.primitive_poses.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.meshes = []
      for i in range(0, length):
        val1 = shape_msgs.msg.Mesh()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.triangles = []
        for i in range(0, length):
          val2 = shape_msgs.msg.MeshTriangle()
          start = end
          end += 12
          val2.vertex_indices = numpy.frombuffer(str[start:end], dtype=numpy.uint32, count=3)
          val1.triangles.append(val2)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.vertices = []
        for i in range(0, length):
          val2 = geometry_msgs.msg.Point()
          _x = val2
          start = end
          end += 24
          (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
          val1.vertices.append(val2)
        self.action_goal.goal.object.meshes.append(val1)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_goal.goal.object.mesh_poses = []
      for i in range(0, length):
        val1 = geometry_msgs.msg.Pose()
        _v189 = val1.position
        _x = _v189
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v190 = val1.orientation
        _x = _v190
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        self.action_goal.goal.object.mesh_poses.append(val1)
      start = end
      end += 32
      self.action_goal.goal.object.surface.coef = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=4)
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_goal.goal.group_name = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_goal.goal.group_name = str[start:end]
      _x = self
      start = end
      end += 12
      (_x.action_result.header.seq, _x.action_result.header.stamp.secs, _x.action_result.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_result.status.goal_id.stamp.secs, _x.action_result.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_result.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_result.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_result.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_result.result.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v191 = val1.pre_grasp_posture
        _v192 = _v191.header
        start = end
        end += 4
        (_v192.seq,) = _get_struct_I().unpack(str[start:end])
        _v193 = _v192.stamp
        _x = _v193
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v192.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v192.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v191.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v191.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v191.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v194 = val3.time_from_start
          _x = _v194
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v191.points.append(val3)
        _v195 = val1.grasp_posture
        _v196 = _v195.header
        start = end
        end += 4
        (_v196.seq,) = _get_struct_I().unpack(str[start:end])
        _v197 = _v196.stamp
        _x = _v197
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v196.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v196.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v195.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v195.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v195.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v198 = val3.time_from_start
          _x = _v198
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v195.points.append(val3)
        _v199 = val1.grasp_pose
        _v200 = _v199.header
        start = end
        end += 4
        (_v200.seq,) = _get_struct_I().unpack(str[start:end])
        _v201 = _v200.stamp
        _x = _v201
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v200.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v200.frame_id = str[start:end]
        _v202 = _v199.pose
        _v203 = _v202.position
        _x = _v203
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v204 = _v202.orientation
        _x = _v204
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v205 = val1.pre_grasp_approach
        _v206 = _v205.direction
        _v207 = _v206.header
        start = end
        end += 4
        (_v207.seq,) = _get_struct_I().unpack(str[start:end])
        _v208 = _v207.stamp
        _x = _v208
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v207.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v207.frame_id = str[start:end]
        _v209 = _v206.vector
        _x = _v209
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v205
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v210 = val1.post_grasp_retreat
        _v211 = _v210.direction
        _v212 = _v211.header
        start = end
        end += 4
        (_v212.seq,) = _get_struct_I().unpack(str[start:end])
        _v213 = _v212.stamp
        _x = _v213
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v212.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v212.frame_id = str[start:end]
        _v214 = _v211.vector
        _x = _v214
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v210
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v215 = val1.post_place_retreat
        _v216 = _v215.direction
        _v217 = _v216.header
        start = end
        end += 4
        (_v217.seq,) = _get_struct_I().unpack(str[start:end])
        _v218 = _v217.stamp
        _x = _v218
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v217.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v217.frame_id = str[start:end]
        _v219 = _v216.vector
        _x = _v219
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v215
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_result.result.grasps.append(val1)
      _x = self
      start = end
      end += 12
      (_x.action_feedback.header.seq, _x.action_feedback.header.stamp.secs, _x.action_feedback.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.header.frame_id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.header.frame_id = str[start:end]
      _x = self
      start = end
      end += 8
      (_x.action_feedback.status.goal_id.stamp.secs, _x.action_feedback.status.goal_id.stamp.nsecs,) = _get_struct_2I().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.goal_id.id = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.goal_id.id = str[start:end]
      start = end
      end += 1
      (self.action_feedback.status.status,) = _get_struct_B().unpack(str[start:end])
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      start = end
      end += length
      if python3:
        self.action_feedback.status.text = str[start:end].decode('utf-8', 'rosmsg')
      else:
        self.action_feedback.status.text = str[start:end]
      start = end
      end += 4
      (length,) = _struct_I.unpack(str[start:end])
      self.action_feedback.feedback.grasps = []
      for i in range(0, length):
        val1 = moveit_msgs.msg.Grasp()
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          val1.id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          val1.id = str[start:end]
        _v220 = val1.pre_grasp_posture
        _v221 = _v220.header
        start = end
        end += 4
        (_v221.seq,) = _get_struct_I().unpack(str[start:end])
        _v222 = _v221.stamp
        _x = _v222
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v221.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v221.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v220.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v220.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v220.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v223 = val3.time_from_start
          _x = _v223
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v220.points.append(val3)
        _v224 = val1.grasp_posture
        _v225 = _v224.header
        start = end
        end += 4
        (_v225.seq,) = _get_struct_I().unpack(str[start:end])
        _v226 = _v225.stamp
        _x = _v226
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v225.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v225.frame_id = str[start:end]
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v224.joint_names = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val3 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val3 = str[start:end]
          _v224.joint_names.append(val3)
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        _v224.points = []
        for i in range(0, length):
          val3 = trajectory_msgs.msg.JointTrajectoryPoint()
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.positions = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.velocities = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.accelerations = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          pattern = '<%sd'%length
          start = end
          s = struct.Struct(pattern)
          end += s.size
          val3.effort = numpy.frombuffer(str[start:end], dtype=numpy.float64, count=length)
          _v227 = val3.time_from_start
          _x = _v227
          start = end
          end += 8
          (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
          _v224.points.append(val3)
        _v228 = val1.grasp_pose
        _v229 = _v228.header
        start = end
        end += 4
        (_v229.seq,) = _get_struct_I().unpack(str[start:end])
        _v230 = _v229.stamp
        _x = _v230
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v229.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v229.frame_id = str[start:end]
        _v231 = _v228.pose
        _v232 = _v231.position
        _x = _v232
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _v233 = _v231.orientation
        _x = _v233
        start = end
        end += 32
        (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
        start = end
        end += 8
        (val1.grasp_quality,) = _get_struct_d().unpack(str[start:end])
        _v234 = val1.pre_grasp_approach
        _v235 = _v234.direction
        _v236 = _v235.header
        start = end
        end += 4
        (_v236.seq,) = _get_struct_I().unpack(str[start:end])
        _v237 = _v236.stamp
        _x = _v237
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v236.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v236.frame_id = str[start:end]
        _v238 = _v235.vector
        _x = _v238
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v234
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v239 = val1.post_grasp_retreat
        _v240 = _v239.direction
        _v241 = _v240.header
        start = end
        end += 4
        (_v241.seq,) = _get_struct_I().unpack(str[start:end])
        _v242 = _v241.stamp
        _x = _v242
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v241.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v241.frame_id = str[start:end]
        _v243 = _v240.vector
        _x = _v243
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v239
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        _v244 = val1.post_place_retreat
        _v245 = _v244.direction
        _v246 = _v245.header
        start = end
        end += 4
        (_v246.seq,) = _get_struct_I().unpack(str[start:end])
        _v247 = _v246.stamp
        _x = _v247
        start = end
        end += 8
        (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        start = end
        end += length
        if python3:
          _v246.frame_id = str[start:end].decode('utf-8', 'rosmsg')
        else:
          _v246.frame_id = str[start:end]
        _v248 = _v245.vector
        _x = _v248
        start = end
        end += 24
        (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
        _x = _v244
        start = end
        end += 8
        (_x.desired_distance, _x.min_distance,) = _get_struct_2f().unpack(str[start:end])
        start = end
        end += 4
        (val1.max_contact_force,) = _get_struct_f().unpack(str[start:end])
        start = end
        end += 4
        (length,) = _struct_I.unpack(str[start:end])
        val1.allowed_touch_objects = []
        for i in range(0, length):
          start = end
          end += 4
          (length,) = _struct_I.unpack(str[start:end])
          start = end
          end += length
          if python3:
            val2 = str[start:end].decode('utf-8', 'rosmsg')
          else:
            val2 = str[start:end]
          val1.allowed_touch_objects.append(val2)
        self.action_feedback.feedback.grasps.append(val1)
      return self
    except struct.error as e:
      raise genpy.DeserializationError(e)  # most likely buffer underfill

_struct_I = genpy.struct_I
def _get_struct_I():
    global _struct_I
    return _struct_I
_struct_2I = None
def _get_struct_2I():
    global _struct_2I
    if _struct_2I is None:
        _struct_2I = struct.Struct("<2I")
    return _struct_2I
_struct_2f = None
def _get_struct_2f():
    global _struct_2f
    if _struct_2f is None:
        _struct_2f = struct.Struct("<2f")
    return _struct_2f
_struct_2i = None
def _get_struct_2i():
    global _struct_2i
    if _struct_2i is None:
        _struct_2i = struct.Struct("<2i")
    return _struct_2i
_struct_3I = None
def _get_struct_3I():
    global _struct_3I
    if _struct_3I is None:
        _struct_3I = struct.Struct("<3I")
    return _struct_3I
_struct_3d = None
def _get_struct_3d():
    global _struct_3d
    if _struct_3d is None:
        _struct_3d = struct.Struct("<3d")
    return _struct_3d
_struct_4d = None
def _get_struct_4d():
    global _struct_4d
    if _struct_4d is None:
        _struct_4d = struct.Struct("<4d")
    return _struct_4d
_struct_B = None
def _get_struct_B():
    global _struct_B
    if _struct_B is None:
        _struct_B = struct.Struct("<B")
    return _struct_B
_struct_B2I = None
def _get_struct_B2I():
    global _struct_B2I
    if _struct_B2I is None:
        _struct_B2I = struct.Struct("<B2I")
    return _struct_B2I
_struct_IBI = None
def _get_struct_IBI():
    global _struct_IBI
    if _struct_IBI is None:
        _struct_IBI = struct.Struct("<IBI")
    return _struct_IBI
_struct_d = None
def _get_struct_d():
    global _struct_d
    if _struct_d is None:
        _struct_d = struct.Struct("<d")
    return _struct_d
_struct_f = None
def _get_struct_f():
    global _struct_f
    if _struct_f is None:
        _struct_f = struct.Struct("<f")
    return _struct_f

# This Python file uses the following encoding: utf-8 autogenerated by genpy from grasping_msgs/GraspPlanningAction.msg. Do not edit. # flag to mark the presence of a Header object # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======  GraspPlanningActionGoal action_goal GraspPlanningActionResult action_result GraspPlanningActionFeedback action_feedback  ================================================================================ MSG: grasping_msgs/GraspPlanningActionGoal # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======  Header header actionlib_msgs/GoalID goal_id GraspPlanningGoal goal  ================================================================================ MSG: std_msgs/Header # Standard metadata for higher-level stamped data types. # This is generally used to communicate timestamped data  # in a particular coordinate frame. #  # sequence ID: consecutively increasing ID  uint32 seq #Two-integer timestamp that is expressed as: # * stamp.sec: seconds (stamp_secs) since epoch (in Python the variable is called 'secs') # * stamp.nsec: nanoseconds since stamp_secs (in Python the variable is called 'nsecs') # time-handling sugar is provided by the client library time stamp #Frame this data is associated with string frame_id  ================================================================================ MSG: actionlib_msgs/GoalID # The stamp should store the time at which this goal was requested. # It is used by an action server when it tries to preempt all # goals that were requested before a certain time time stamp  # The id provides a way to associate feedback and # result message with specific goal requests. The id # specified must be unique. string id   ================================================================================ MSG: grasping_msgs/GraspPlanningGoal # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== ########################################################### # This action is used when planning grasps for a single, #  already known object, one object at a time.  # Object for which grasp planning is requested Object object  # Name of group to plan with (optional) string group_name  ================================================================================ MSG: grasping_msgs/Object ########################################################### # This message describes an object.  # Many of the geometric items below lack a stamp/frame_id, # header stamp/frame_id should be used there std_msgs/Header header  # An object might have a name string name  # An object might have a known (named) support surface string support_surface  # Objects might have properties, such as type/class, or color, etc. ObjectProperty[] properties  ########################################################### # Objects have many possible descriptions #  The following are the possible description formats  # Perception modules often represent an object as a cluster of points #  Is considered valid if number of points > 0 sensor_msgs/PointCloud2 point_cluster  # MoveIt prefers solid primitives or meshes as a description of objects shape_msgs/SolidPrimitive[] primitives geometry_msgs/Pose[] primitive_poses  shape_msgs/Mesh[] meshes geometry_msgs/Pose[] mesh_poses  # An object representing a support surface might be described by a plane # Is considered valid if coefficients are not all 0s. shape_msgs/Plane surface  ================================================================================ MSG: grasping_msgs/ObjectProperty ########################################################### # Other generic properties of an object string name string value  ================================================================================ MSG: sensor_msgs/PointCloud2 # This message holds a collection of N-dimensional points, which may # contain additional information such as normals, intensity, etc. The # point data is stored as a binary blob, its layout described by the # contents of the "fields" array.  # The point cloud data may be organized 2d (image-like) or 1d # (unordered). Point clouds organized as 2d images may be produced by # camera depth sensors such as stereo or time-of-flight.  # Time of sensor data acquisition, and the coordinate frame ID (for 3d # points). Header header  # 2D structure of the point cloud. If the cloud is unordered, height is # 1 and width is the length of the point cloud. uint32 height uint32 width  # Describes the channels and their layout in the binary data blob. PointField[] fields  bool    is_bigendian # Is this data bigendian? uint32  point_step   # Length of a point in bytes uint32  row_step     # Length of a row in bytes uint8[] data         # Actual point data, size is (row_step*height)  bool is_dense        # True if there are no invalid points  ================================================================================ MSG: sensor_msgs/PointField # This message holds the description of one point entry in the # PointCloud2 message format. uint8 INT8    = 1 uint8 UINT8   = 2 uint8 INT16   = 3 uint8 UINT16  = 4 uint8 INT32   = 5 uint8 UINT32  = 6 uint8 FLOAT32 = 7 uint8 FLOAT64 = 8  string name      # Name of field uint32 offset    # Offset from start of point struct uint8  datatype  # Datatype enumeration, see above uint32 count     # How many elements in the field  ================================================================================ MSG: shape_msgs/SolidPrimitive # Define box, sphere, cylinder, cone  # All shapes are defined to have their bounding boxes centered around 0,0,0.  uint8 BOX=1 uint8 SPHERE=2 uint8 CYLINDER=3 uint8 CONE=4  # The type of the shape uint8 type   # The dimensions of the shape float64[] dimensions  # The meaning of the shape dimensions: each constant defines the index in the 'dimensions' array  # For the BOX type, the X, Y, and Z dimensions are the length of the corresponding # sides of the box. uint8 BOX_X=0 uint8 BOX_Y=1 uint8 BOX_Z=2   # For the SPHERE type, only one component is used, and it gives the radius of # the sphere. uint8 SPHERE_RADIUS=0   # For the CYLINDER and CONE types, the center line is oriented along # the Z axis.  Therefore the CYLINDER_HEIGHT (CONE_HEIGHT) component # of dimensions gives the height of the cylinder (cone).  The # CYLINDER_RADIUS (CONE_RADIUS) component of dimensions gives the # radius of the base of the cylinder (cone).  Cone and cylinder # primitives are defined to be circular. The tip of the cone is # pointing up, along +Z axis.  uint8 CYLINDER_HEIGHT=0 uint8 CYLINDER_RADIUS=1  uint8 CONE_HEIGHT=0 uint8 CONE_RADIUS=1  ================================================================================ MSG: geometry_msgs/Pose # A representation of pose in free space, composed of position and orientation.  Point position Quaternion orientation  ================================================================================ MSG: geometry_msgs/Point # This contains the position of a point in free space float64 x float64 y float64 z  ================================================================================ MSG: geometry_msgs/Quaternion # This represents an orientation in free space in quaternion form.  float64 x float64 y float64 z float64 w  ================================================================================ MSG: shape_msgs/Mesh # Definition of a mesh  # list of triangles; the index values refer to positions in vertices[] MeshTriangle[] triangles  # the actual vertices that make up the mesh geometry_msgs/Point[] vertices  ================================================================================ MSG: shape_msgs/MeshTriangle # Definition of a triangle's vertices uint32[3] vertex_indices  ================================================================================ MSG: shape_msgs/Plane # Representation of a plane, using the plane equation ax + by + cz + d = 0  # a := coef[0] # b := coef[1] # c := coef[2] # d := coef[3]  float64[4] coef  ================================================================================ MSG: grasping_msgs/GraspPlanningActionResult # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======  Header header actionlib_msgs/GoalStatus status GraspPlanningResult result  ================================================================================ MSG: actionlib_msgs/GoalStatus GoalID goal_id uint8 status uint8 PENDING         = 0   # The goal has yet to be processed by the action server uint8 ACTIVE          = 1   # The goal is currently being processed by the action server uint8 PREEMPTED       = 2   # The goal received a cancel request after it started executing                             #   and has since completed its execution (Terminal State) uint8 SUCCEEDED       = 3   # The goal was achieved successfully by the action server (Terminal State) uint8 ABORTED         = 4   # The goal was aborted during execution by the action server due                             #    to some failure (Terminal State) uint8 REJECTED        = 5   # The goal was rejected by the action server without being processed,                             #    because the goal was unattainable or invalid (Terminal State) uint8 PREEMPTING      = 6   # The goal received a cancel request after it started executing                             #    and has not yet completed execution uint8 RECALLING       = 7   # The goal received a cancel request before it started executing,                             #    but the action server has not yet confirmed that the goal is canceled uint8 RECALLED        = 8   # The goal received a cancel request before it started executing                             #    and was successfully cancelled (Terminal State) uint8 LOST            = 9   # An action client can determine that a goal is LOST. This should not be                             #    sent over the wire by an action server  #Allow for the user to associate a string with GoalStatus for debugging string text   ================================================================================ MSG: grasping_msgs/GraspPlanningResult # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== # All grasps moveit_msgs/Grasp[] grasps  ================================================================================ MSG: moveit_msgs/Grasp # This message contains a description of a grasp that would be used # with a particular end-effector to grasp an object, including how to # approach it, grip it, etc.  This message does not contain any # information about a "grasp point" (a position ON the object). # Whatever generates this message should have already combined # information about grasp points with information about the geometry # of the end-effector to compute the grasp_pose in this message.  # A name for this grasp string id  # The internal posture of the hand for the pre-grasp # only positions are used trajectory_msgs/JointTrajectory pre_grasp_posture  # The internal posture of the hand for the grasp # positions and efforts are used trajectory_msgs/JointTrajectory grasp_posture  # The position of the end-effector for the grasp.  This is the pose of # the "parent_link" of the end-effector, not actually the pose of any # link *in* the end-effector.  Typically this would be the pose of the # most distal wrist link before the hand (end-effector) links began. geometry_msgs/PoseStamped grasp_pose  # The estimated probability of success for this grasp, or some other # measure of how "good" it is. float64 grasp_quality  # The approach direction to take before picking an object GripperTranslation pre_grasp_approach  # The retreat direction to take after a grasp has been completed (object is attached) GripperTranslation post_grasp_retreat  # The retreat motion to perform when releasing the object; this information # is not necessary for the grasp itself, but when releasing the object, # the information will be necessary. The grasp used to perform a pickup # is returned as part of the result, so this information is available for  # later use. GripperTranslation post_place_retreat  # the maximum contact force to use while grasping (<=0 to disable) float32 max_contact_force  # an optional list of obstacles that we have semantic information about # and that can be touched/pushed/moved in the course of grasping string[] allowed_touch_objects  ================================================================================ MSG: trajectory_msgs/JointTrajectory Header header string[] joint_names JointTrajectoryPoint[] points  ================================================================================ MSG: trajectory_msgs/JointTrajectoryPoint # Each trajectory point specifies either positions[, velocities[, accelerations]] # or positions[, effort] for the trajectory to be executed. # All specified values are in the same order as the joint names in JointTrajectory.msg  float64[] positions float64[] velocities float64[] accelerations float64[] effort duration time_from_start  ================================================================================ MSG: geometry_msgs/PoseStamped # A Pose with reference coordinate frame and timestamp Header header Pose pose  ================================================================================ MSG: moveit_msgs/GripperTranslation # defines a translation for the gripper, used in pickup or place tasks # for example for lifting an object off a table or approaching the table for placing  # the direction of the translation geometry_msgs/Vector3Stamped direction  # the desired translation distance float32 desired_distance  # the min distance that must be considered feasible before the # grasp is even attempted float32 min_distance  ================================================================================ MSG: geometry_msgs/Vector3Stamped # This represents a Vector3 with reference coordinate frame and timestamp Header header Vector3 vector  ================================================================================ MSG: geometry_msgs/Vector3 # This represents a vector in free space.  # It is only meant to represent a direction. Therefore, it does not # make sense to apply a translation to it (e.g., when applying a  # generic rigid transformation to a Vector3, tf2 will only apply the # rotation). If you want your data to be translatable too, use the # geometry_msgs/Point message instead.  float64 x float64 y float64 z ================================================================================ MSG: grasping_msgs/GraspPlanningActionFeedback # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======  Header header actionlib_msgs/GoalStatus status GraspPlanningFeedback feedback  ================================================================================ MSG: grasping_msgs/GraspPlanningFeedback # ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ====== # Grasps found thus far moveit_msgs/Grasp[] grasps Constructor. Any message fields that are implicitly/explicitly     set to None will be assigned a default value. The recommend     use is keyword arguments as this is more robust to future message     changes.  You cannot mix in-order arguments and keyword arguments.      The available fields are:        action_goal,action_result,action_feedback      :param args: complete set of field values, in .msg order     :param kwds: use keyword arguments corresponding to message field names     to set specific fields. # message fields cannot be None, assign default values for those that are internal API method serialize message into buffer     :param buff: buffer, ``StringIO`` # - if encoded as a list instead, serialize as bytes instead of string unpack serialized message in str into this message instance     :param str: byte array of serialized message, ``str`` # most likely buffer underfill serialize message with numpy array types into buffer     :param buff: buffer, ``StringIO``     :param numpy: numpy python module # - if encoded as a list instead, serialize as bytes instead of string unpack serialized message in str into this message instance using numpy for array types     :param str: byte array of serialized message, ``str``     :param numpy: numpy python module # most likely buffer underfill