def serialize_numpy(self, buff, numpy):
    '\n    serialize message with numpy array types into buffer\n    :param buff: buffer, ``StringIO``\n    :param numpy: numpy python module\n    '
    try:
        _x = self
        buff.write(_get_struct_3I().pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
        _x = self.header.frame_id
        length = len(_x)
        if (python3 or (type(_x) == unicode)):
            _x = _x.encode('utf-8')
            length = len(_x)
        buff.write(struct.pack(('<I%ss' % length), length, _x))
        _x = self
        buff.write(_get_struct_2B9d().pack(_x.sysid, _x.compid, _x.acc.x, _x.acc.y, _x.acc.z, _x.gyro.x, _x.gyro.y, _x.gyro.z, _x.mag.x, _x.mag.y, _x.mag.z))
    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))))))
serialize message with numpy array types into buffer
:param buff: buffer, ``StringIO``
:param numpy: numpy python module
def serialize_numpy(self, buff, numpy):
    '\n    serialize message with numpy array types into buffer\n    :param buff: buffer, ``StringIO``\n    :param numpy: numpy python module\n    '
    try:
        _x = self
        buff.write(_get_struct_3I().pack(_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs))
        _x = self.header.frame_id
        length = len(_x)
        if (python3 or (type(_x) == unicode)):
            _x = _x.encode('utf-8')
            length = len(_x)
        buff.write(struct.pack(('<I%ss' % length), length, _x))
        _x = self
        buff.write(_get_struct_2B9d().pack(_x.sysid, _x.compid, _x.acc.x, _x.acc.y, _x.acc.z, _x.gyro.x, _x.gyro.y, _x.gyro.z, _x.mag.x, _x.mag.y, _x.mag.z))
    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))))))