Exemplo n.º 1
0
            det_performance = eval.measure_detection_performance(
                detections, frame.laser_labels, valid_label_flags)
        else:
            print('loading detection performance measures from file')
            det_performance = load_object_from_file(
                results_fullpath, data_filename, 'det_performance_' +
                configs_det.arch + '_' + str(configs_det.conf_thresh),
                cnt_frame)

        det_performance_all.append(
            det_performance
        )  # store all evaluation results in a list for performance assessment at the end

        ## Visualization for object detection
        if 'show_range_image' in exec_list:
            img_range = pcl.show_range_image(frame)  #lider_name S3
            img_range = img_range.astype(np.uint8)
            cv2.imshow('range_image', img_range)
            cv2.waitKey(vis_pause_time)

        if 'show_pcl' in exec_list:
            pcl.show_pcl(lidar_pcl)

        if 'show_bev' in exec_list:
            tools.show_bev(lidar_bev, configs_det)
            cv2.waitKey(vis_pause_time)

        if 'show_labels_in_image' in exec_list:
            img_labels = tools.project_labels_into_camera(
                camera_calibration, image, frame.laser_labels,
                valid_label_flags, 0.5)
Exemplo n.º 2
0
                detections, frame.laser_labels, valid_label_flags,
                configs_det.min_iou)
        else:
            print('loading detection performance measures from file')
            # det_performance = load_object_from_file(results_fullpath, data_filename, 'det_performance_' + configs_det.arch + '_' + str(configs_det.conf_thresh), cnt_frame)
            det_performance = load_object_from_file(results_fullpath,
                                                    data_filename,
                                                    'det_performance',
                                                    cnt_frame)
        det_performance_all.append(
            det_performance
        )  # store all evaluation results in a list for performance assessment at the end

        ## Visualization for object detection
        if 'show_range_image' in exec_list:
            img_range = pcl.show_range_image(frame, lidar_name)
            img_range = img_range.astype(np.uint8)
            cv2.imshow('range_image', img_range)
            cv2.waitKey(vis_pause_time)

        if 'show_pcl' in exec_list:
            pcl.show_pcl(lidar_pcl)

        if 'show_bev' in exec_list:
            tools.show_bev(lidar_bev, configs_det)
            cv2.waitKey(vis_pause_time)

        if 'show_labels_in_image' in exec_list:
            img_labels = tools.project_labels_into_camera(
                camera_calibration, image, frame.laser_labels,
                valid_label_flags, 0.5)