detection_utils
最后更新
depthai_nodes.message.utils.detection_utils函数
compute_area
Python
1def compute_area(detection: dai.ImgDetection | dai.SpatialImgDetection):detection(dai.ImgDetection | dai.SpatialImgDetection): 用于计算面积的检测对象。可以是 dai.ImgDetection 或 dai.SpatialImgDetection 类型。
float: 检测边界框的归一化面积(宽度 * 高度)。