Protobuf Reader

A class for reading Protobuf data from a DataFile.

class bosdyn.bddf.protobuf_reader.ProtobufReader(data_reader)[source]

Bases: MessageReader

A class for reading Protobuf data from a DataFile.

Methods raise ParseError if there is a problem with the format of the file.

get_message(series_index, protobuf_type, index_in_series)[source]

Return a deserialized protobuf from bytes stored in the file.

Parameters:
  • series_index – index (int) from the series_index() call

  • protobuf_type – class of the protobuf we want to deserialize

  • index_in_series – the index of the message within the series

Returns: DataTypeDescriptor for channel, timestamp_nsec (int), deserialized protobuf object