Class MsgPackValidator

Class Documentation

class MsgPackValidator

Public Functions

MsgPackValidator(const std::vector<int> &echos = {0, 1, 2}, float azimuth_start = -M_PI, float azimuth_end = M_PI, float elevation_start = -M_PI / 2.0, float elevation_end = M_PI / 2.0, const std::vector<int> &segments = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11}, const std::vector<int> &layer_filter = {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}, int verbose = 0)
~MsgPackValidator()
bool validateNotOutOfBound(const MsgPackValidatorData &data_received) const
bool validateNoMissingScandata(const MsgPackValidatorData &msgpack_data_collected) const

Protected Functions

template<typename T>
inline std::string listVector(const std::vector<T> &vec) const

prints a vector as a flat list

int getAzimuthHistogramCount(const MsgPackValidatorData::AzimuthHistogramPerElevationPerSegmentPerEcho &azimuth_histogram, int echo_idx, int segment_idx, int elevation_idx, int azimuth_idx) const

Returns the number of azimuth angles counted in the histogram for a given echo, segment, elevation and azimuth

void printMissingHistogramData(const std::vector<std::string> &messages) const

Protected Attributes

std::vector<int> m_echos_required
float m_azimuth_start
float m_azimuth_end
float m_elevation_start
float m_elevation_end
std::vector<int> m_valid_segments
std::vector<int> m_layer_filter
int m_verbose