39 lines
1.1 KiB
Protocol Buffer Text Format
39 lines
1.1 KiB
Protocol Buffer Text Format
# MediaPipe graph that performs hand detection on desktop with TensorFlow Lite
|
|
# on CPU.
|
|
# Used in the example in
|
|
# mediapipe/examples/desktop/hand_tracking:hand_detection_cpu.
|
|
|
|
# Images coming into and out of the graph.
|
|
input_stream: "input_video"
|
|
output_stream: "output_video"
|
|
|
|
# Performs hand detection model on the input frames. See
|
|
# hand_detection_cpu.pbtxt for the detail of the sub-graph.
|
|
node {
|
|
calculator: "HandDetectionSubgraph"
|
|
input_stream: "input_video"
|
|
output_stream: "DETECTIONS:output_detections"
|
|
}
|
|
|
|
# Converts the detections to drawing primitives for annotation overlay.
|
|
node {
|
|
calculator: "DetectionsToRenderDataCalculator"
|
|
input_stream: "DETECTIONS:output_detections"
|
|
output_stream: "RENDER_DATA:render_data"
|
|
node_options: {
|
|
[type.googleapis.com/mediapipe.DetectionsToRenderDataCalculatorOptions] {
|
|
thickness: 4.0
|
|
color { r: 0 g: 255 b: 0 }
|
|
}
|
|
}
|
|
}
|
|
|
|
# Draws annotations and overlays them on top of the original image coming into
|
|
# the graph.
|
|
node {
|
|
calculator: "AnnotationOverlayCalculator"
|
|
input_stream: "IMAGE:input_video"
|
|
input_stream: "render_data"
|
|
output_stream: "IMAGE:output_video"
|
|
}
|