You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

184 lines
5.1 KiB

syntax = "proto3";
package innovatrics.embedded.frame_data;
import "google/protobuf/timestamp.proto";
message FrameData {
// timestamp of the frame the message was generated for
google.protobuf.Timestamp timestamp = 1;
// incremental frame number
uint64 frame_number = 2;
// full frame image
Image frame_image = 3;
// vector of detected faces
repeated FaceData face_data = 4;
// vector of lost objects
repeated LostObjectData lost_object_data = 5;
// client_id (same as MQTT client ID) of the source camera/device which produced the message
string client_id = 6;
}
message FaceData {
// face detection data
FaceDetectionData face_detection_data = 1;
// face tracking data
TrackingData face_tracking_data = 2;
// face landmarks data
repeated FaceLandmarkData landmarks_data = 3;
// face mask status data
optional FaceMaskData face_mask_data = 4;
// cropping data
optional CroppingData cropping_data = 5;
// liveness detection data
repeated LivenessData liveness_data = 6;
// face template extraction
optional TemplateData template_data = 7;
// face identification
repeated IdentificationData identification_data = 8;
}
message FaceDetectionData {
// bounding box of detected face
BoundingBox bounding_box = 1;
// normalized value detection confidence of detected face - range <0,1>
float detection_confidence = 2;
// raw value of detection confidence of detected face - range <0,1>
float raw_detection_confidence = 3;
}
message TrackingData {
// tracking ID (ByteTrack) assigned to detected object
uint32 tracking_id = 1;
// tracking UUID assigned to detected object
string tracking_uuid = 2;
// tracking state (ByteTrack) of detected object
TrackingState tracking_state = 3;
}
message FaceLandmarkData {
// type of the keypoint detected in the face
FaceKeypointType keypoint_type = 1;
// confidence of the keypoint detected in the face - range <0,1>
float confidence = 2;
// X coordinate of the keypoint relative to full frame - range <0,1>
float x = 3;
// Y coordinate of the keypoint relative to full frame - range <0,1>
float y = 4;
}
message FaceMaskData {
// face mask detection confidence - range <0,1>
float confidence = 1;
}
message CroppingData {
// extension of the crop image specified in settings
uint32 crop_extension = 1;
// bounding box of the crop
optional BoundingBox crop_box = 2;
// crop image of detected object
optional Image crop_image = 3;
}
message LivenessData {
// type of liveness detection algorithm
LivenessType liveness_type = 1;
// liveness detection score
float score = 2;
}
message TemplateData {
bytes template = 1;
}
message IdentificationData {
// user id
uint32 id = 1;
// user name
string name = 2;
// match score
float score = 3;
}
message Image {
// width of the image - absolute value
uint32 width = 1;
// height of the image - absolute value
uint32 height = 2;
// image data in specified format
optional bytes data = 3;
// format of the image data specified in settings
ImageFormat image_format = 4;
}
// image format enumeration
enum ImageFormat {
// default
RawBgr = 0;
// Jpeg
Jpeg = 1;
// Png
Png = 2;
}
message BoundingBox {
// X coordinate of left upper corner of bounding box relative to full frame - range <0,1>
float x = 1;
// Y coordinate of left upper corner of bounding box relative to full frame - range <0,1>
float y = 2;
// width of bounding box relative to width of full frame - range <0,1>
float width = 3;
// height of bounding box relative to height of full frame - range <0,1>
float height = 4;
}
// tracking state enumeration (defined by ByteTrack)
enum TrackingState {
New = 0;
Tracked = 1;
Lost = 2;
Removed = 3;
}
// face keypoint type enumeration
enum FaceKeypointType {
RightEyeOuterCorner = 0;
RightEyeCentre = 1;
RightEyeInnerCorner = 2;
LeftEyeInnerCorner = 3;
LeftEyeCentre = 4;
LeftEyeOuterCorner = 5;
NoseRoot = 6;
NoseRightBottom = 7;
NoseTip = 8;
NoseLeftBottom = 9;
NoseBottom = 10;
MouthRightCorner = 11;
MouthCenter = 12;
MouthLeftCorner = 13;
MouthUpperEdge = 14;
MouthLowerEdge = 15;
RightEyebrowOuterEnd = 16;
RightEyebrowInnerEnd = 17;
LeftEyebrowInnerEnd = 18;
LeftEyebrowOuterEnd = 19;
RightEdge = 20;
ChinTip = 21;
LeftEdge = 22;
}
// liveness detection algorithm enumeration
enum LivenessType {
// default
Distant = 0;
}
message LostObjectData {
// tracking UUID of the lost object
string tracking_uuid = 1;
// timestamp of the frame where the object appeared first time (New in ByteTrack)
google.protobuf.Timestamp first_time_appeared = 2;
// timestamp of the frame where ByteTrack change the tracking status of the object to Removed
google.protobuf.Timestamp last_time_appeared = 3;
// crop of best appearance of the object in tracklet - NOT SUPPORTED YET
optional Image best_crop_image = 4;
}