VRS
A file format for sensor data.
Loading...
Searching...
No Matches
Functions | Variables
vrs::tag_conventions Namespace Reference

Namespace for tag names following standardized conventions. More...

Functions

std::string addUniqueSessionId (RecordFileWriter &writer)
 
void addCaptureTime (RecordFileWriter &writer)
 
void addTagSet (RecordFileWriter &writer, const vector< string > &tags)
 
template<class T >
void addDevice (T &writer, const string &type, const string &serialNumber, const string &version)
 
template<class T >
void addDeviceId (T &writer, const string &id)
 
void addOsFingerprint (RecordFileWriter &writer)
 
void addSoftwareDetails (RecordFileWriter &writer, const string &compileDate, const string &rev)
 
template<class T >
void addFirmwareDetails (T &writer, const string &fwCompileDate, const string &fwRevision)
 
string makeTagSet (const vector< string > &tags)
 
bool parseTagSet (const string &jsonTagSet, vector< string > &outVectorTagSet)
 

Variables

constexpr const char * kProjectName = "project_name"
 
constexpr const char * kCaptureTimeEpoch = "capture_time_epoch"
 
constexpr const char * kSessionId = "session_id"
 
constexpr const char * kCaptureType = "capture_type"
 
constexpr const char * kTagSet = "tag_set"
 
constexpr const char * kDeviceType = "device_type"
 
constexpr const char * kDeviceVersion = "device_version"
 
constexpr const char * kDeviceSerial = "device_serial"
 
constexpr const char * kDeviceId = "device_id"
 
constexpr const char * kHardwareConfiguration = "hardware_configuration"
 
constexpr const char * kOsFingerprint = "os_fingerprint"
 
constexpr const char * kOsBuildVersion = "os_build_version"
 
constexpr const char * kOsBranch = "os_branch"
 
constexpr const char * kSoftwareCompileDate = "software_compile_date"
 
constexpr const char * kSoftwareRevision = "software_revision"
 
constexpr const char * kFirmwareCompileDate = "firmware_compile_date"
 
constexpr const char * kFirmwareRevision = "firmware_revision"
 
constexpr const char * kDeviceRole = "device_role"
 
constexpr const char * kDynamicExposureTarget = "iot_dynamic_exposure_target"
 
constexpr const char * kImageSemantic = "image_semantic"
 Tag name to hint how to normalize a stream's images.
 
constexpr const char * kImageSemanticCamera = "image_semantic_camera"
 Possible values for kImageSemantic.
 
constexpr const char * kImageSemanticDepth = "image_semantic_depth"
 Depth camera.
 
constexpr const char * kImageSemanticObjectClassSegmentation
 Object class segmentation.
 
constexpr const char * kImageSemanticObjectIdSegmentation
 Object ID segmentation.
 
constexpr const char * kRenderDepthImagesRangeMin = "render_depth_images_range_min"
 
constexpr const char * kRenderDepthImagesRangeMax = "render_depth_images_range_max"
 

Detailed Description

Namespace for tag names following standardized conventions.

Function Documentation

◆ addCaptureTime()

void vrs::tag_conventions::addCaptureTime ( RecordFileWriter writer)

Add a capture time tag, using the current time.

Parameters
writerthe file writer to add the tag to.

◆ addDevice()

template<class T >
void vrs::tag_conventions::addDevice ( T &  writer,
const string &  type,
const string &  serialNumber,
const string &  version 
)
inline

Add tags describing a device.

Parameters
writerthe file writer, or a recordable to describe.
typea device type description.
serialNumberthe device's serial number.
versionthe device's version number.

◆ addDeviceId()

template<class T >
void vrs::tag_conventions::addDeviceId ( T &  writer,
const string &  id 
)
inline

Add a tag for the device ID.

Parameters
writerthe file writer, or a recordable to describe.
idthe device's ID.

◆ addFirmwareDetails()

template<class T >
void vrs::tag_conventions::addFirmwareDetails ( T &  writer,
const string &  fwCompileDate,
const string &  fwRevision 
)
inline

Add tags describing the FW version of the main device or the recordable.

Parameters
writerthe file writer or a recordable to describe.
fwCompileDatethe FW's compile date.
fwRevisionthe FW's revision number.

◆ addOsFingerprint()

void vrs::tag_conventions::addOsFingerprint ( RecordFileWriter writer)

Add a tag describing the OS version.

Parameters
writerthe file writer to attach the tag to.

◆ addSoftwareDetails()

void vrs::tag_conventions::addSoftwareDetails ( RecordFileWriter writer,
const string &  compileDate,
const string &  rev 
)
inline

Add a tag describing the running software version.

Parameters
writerthe file writer to attach the tag to.
compileDatethe software's compile date.
revthe software's revision number.

◆ addTagSet()

void vrs::tag_conventions::addTagSet ( RecordFileWriter writer,
const vector< string > &  tags 
)

Add a set of tags to a file.

Parameters
writerthe file writer to add the tagset to.
tagsa vector of text tags.

◆ addUniqueSessionId()

string vrs::tag_conventions::addUniqueSessionId ( RecordFileWriter writer)

Add a unique session id tag, generated then.

Parameters
writerthe file writer to add the tag to.
Returns
The generated session ID.

◆ makeTagSet()

string vrs::tag_conventions::makeTagSet ( const vector< string > &  tags)

Convert a set of string tags to json.

Parameters
tagsA set of string tags.
Returns
A json string containing all the tags.

◆ parseTagSet()

bool vrs::tag_conventions::parseTagSet ( const string &  jsonTagSet,
vector< string > &  outVectorTagSet 
)

Convert a json tag set back to a vector of string tags.

Parameters
jsonTagSetjson string containing the tags.
outVectorTagSetvector of strings where to place the tags parsed.
Returns
True if parsing worked (might still not be real tagset).

Variable Documentation

◆ kImageSemanticCamera

constexpr const char* vrs::tag_conventions::kImageSemanticCamera = "image_semantic_camera"
constexpr

Possible values for kImageSemantic.

Regular camera

◆ kImageSemanticObjectClassSegmentation

constexpr const char* vrs::tag_conventions::kImageSemanticObjectClassSegmentation
constexpr
Initial value:
=
"image_semantic_object_class_segmentation"

Object class segmentation.

◆ kImageSemanticObjectIdSegmentation

constexpr const char* vrs::tag_conventions::kImageSemanticObjectIdSegmentation
constexpr
Initial value:
=
"image_semantic_object_id_segmentation"

Object ID segmentation.

◆ kRenderDepthImagesRangeMin

constexpr const char* vrs::tag_conventions::kRenderDepthImagesRangeMin = "render_depth_images_range_min"
constexpr

When kImageSemantic == kImageSemanticDepth Tag names to provide depth range values. float values expected as string. Hint for depth image rendering, actual value range may be smaller or larger.