Attention: This MediaPipe Solutions Preview is an early release. Learn more.

mp.packet_creator.create_proto

Stay organized with collections Save and categorize content based on your preferences.

Create a MediaPipe protobuf message packet.

proto_message A Python protobuf message.

A MediaPipe protobuf message Packet.

RuntimeError If the protobuf message type is not registered in MediaPipe.

detection = detection_pb2.Detection() text_format.Parse('score: 0.5', detection) packet = mp.packet_creator.create_proto(detection) output_detection = mp.packet_getter.get_proto(packet)