rosbags.serde

Rosbags message serialization and deserialization.

Serializers and deserializers convert between python messages objects and the common rosbag serialization formats. Computationally cheap functions convert directly between different serialization formats.

exception rosbags.serde.SerdeError

Bases: Exception

Serialization and Deserialization Error.

rosbags.serde.cdr_to_ros1(raw, typename, typestore=None)

DEPRECATED.

Return type:

memoryview

Parameters:
  • raw (bytes | memoryview)

  • typename (str)

  • typestore (Typestore | None)

rosbags.serde.deserialize_cdr(rawdata, typename, typestore=None)

DEPRECATED.

Return type:

object

Parameters:
  • rawdata (bytes | memoryview)

  • typename (str)

  • typestore (Typestore | None)

rosbags.serde.deserialize_ros1(rawdata, typename, typestore=None)

DEPRECATED.

Return type:

object

Parameters:
  • rawdata (bytes | memoryview)

  • typename (str)

  • typestore (Typestore | None)

rosbags.serde.ros1_to_cdr(raw, typename, typestore=None)

DEPRECATED.

Return type:

memoryview

Parameters:
  • raw (bytes | memoryview)

  • typename (str)

  • typestore (Typestore | None)

rosbags.serde.serialize_cdr(message, typename, *, little_endian=True, typestore=None)

DEPRECATED.

Return type:

memoryview

Parameters:
  • message (object)

  • typename (str)

  • little_endian (bool)

  • typestore (Typestore | None)

rosbags.serde.serialize_ros1(message, typename, typestore=None)

DEPRECATED.

Return type:

memoryview

Parameters:
  • message (object)

  • typename (str)

  • typestore (Typestore | None)