如何使用张量流查找对象/盒子坐标?

时间:2019-06-21 18:46:58

标签: python tensorflow

我正在尝试使用张量流检测手部动作。我看过代码并运行了它,它确实为手部检测提供了良好的结果。但是它没有检测到手坐标。我已经尝试通过应用我所知道的但是相同的结果来构思x和y轴。如果有人让我理解如何从下面的代码中获取轴详细信息,我将非常高兴。是检测手轴还是框轴。


    while True:

        ret, image_np = cap.read()
        try:
            image_np = cv2.cvtColor(image_np, cv2.COLOR_BGR2RGB)
        except:
            print("Error converting to RGB")

        # Actual detection. Variable boxes contains the bounding box cordinates for hands detected,
        # while scores contains the confidence for each of these boxes.
        # Hint: If len(boxes) > 1 , you may assume you have found atleast one hand (within your score threshold)

        boxes, scores = detector_utils.detect_objects(image_np,
                                                      detection_graph, sess)

        # draw bounding boxes on frame
        detector_utils.draw_box_on_image(num_hands_detect, args.score_thresh,scores, boxes, im_width, im_height,image_np)

0 个答案:

没有答案