Skip to content

OpenPCDet LiDar Object Detection Node #399

OpenPCDet LiDar Object Detection Node

OpenPCDet LiDar Object Detection Node #399

Triggered via pull request February 23, 2024 02:59
Status Failure
Total duration 2h 1m 45s
Artifacts

build_and_unitest.yml

on: pull_request
Setup environment
24s
Setup environment
Matrix: Build Image and Run Unit Testing Suite
Confirm Build and Unit Tests Completed
0s
Confirm Build and Unit Tests Completed
Fit to window
Zoom out
Zoom in

Annotations

11 errors, 1 warning, and 3 notices
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L1
+from vision_msgs.msg import ObjectHypothesisWithPose, Detection3D, Detection3DArray +from visualization_msgs.msg import Marker, MarkerArray +from pcdet.utils import common_utils +from pcdet.models import build_network, load_data_to_gpu +from pcdet.datasets import DatasetTemplate +from pcdet.config import cfg, cfg_from_yaml_file import argparse import rclpy from rclpy.node import Node
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L7
import torch import sys sys.path.append('/home/bolty/OpenPCDet') -from pcdet.config import cfg, cfg_from_yaml_file -from pcdet.datasets import DatasetTemplate -from pcdet.models import build_network, load_data_to_gpu -from pcdet.utils import common_utils -from visualization_msgs.msg import Marker, MarkerArray -from vision_msgs.msg import ObjectHypothesisWithPose, Detection3D, Detection3DArray + class LidarObjectDetection(Node): def __init__(self): super().__init__('lidar_object_detection') self.declare_parameter("model_path", "/home/bolty/OpenPCDet/models/pv_rcnn_8369.pth") - self.declare_parameter("model_config_path", "/home/bolty/OpenPCDet/tools/cfgs/kitti_models/pv_rcnn.yaml") + self.declare_parameter("model_config_path", + "/home/bolty/OpenPCDet/tools/cfgs/kitti_models/pv_rcnn.yaml") self.declare_parameter("lidar_topic", "/velodyne_points") self.model_path = self.get_parameter("model_path").value self.model_config_path = self.get_parameter("model_config_path").value
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L35
args, cfg = self.parse_config() self.logger = common_utils.create_logger() - self.logger.info('-------------------------Starting Lidar Object Detection-------------------------') + self.logger.info( + '-------------------------Starting Lidar Object Detection-------------------------') self.demo_dataset = LidarDataset( dataset_cfg=cfg.DATA_CONFIG, class_names=cfg.CLASS_NAMES, training=False, logger=self.logger) - self.model = build_network(model_cfg=cfg.MODEL, num_class=len(cfg.CLASS_NAMES), dataset=self.demo_dataset) + self.model = build_network(model_cfg=cfg.MODEL, num_class=len( + cfg.CLASS_NAMES), dataset=self.demo_dataset) self.model.load_params_from_file(filename=args.ckpt, logger=self.logger, to_cpu=True) self.model.cuda() self.model.eval()
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L92
marker.color.g = 0.0 marker.color.b = float(pred_dicts[0]['pred_labels'][idx]) / 3 marker_array.markers.append(marker) - + detections = Detection3DArray() detections.header = pointcloud_msg.header for idx, box in enumerate(pred_dicts[0]['pred_boxes']):
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L109
detected_object.hypothesis.score = float(pred_dicts[0]['pred_scores'][idx]) detection.results.append(detected_object) detections.detections.append(detection) - + self.bbox_publisher.publish(marker_array) self.detections_publisher.publish(detections)
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L117
parser = argparse.ArgumentParser(description='arg parser') parser.add_argument('--cfg_file', type=str, default=self.model_config_path, help='specify the config for demo') - parser.add_argument('--ckpt', type=str, default=self.model_path, help='specify the pretrained model') + parser.add_argument('--ckpt', type=str, default=self.model_path, + help='specify the pretrained model') args, _ = parser.parse_known_args() cfg_from_yaml_file(args.cfg_file, cfg) return args, cfg - def create_cloud_xyz32(self, header, points): """ Create a sensor_msgs/PointCloud2 message from an array of points.
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L142
y_angle = np.deg2rad(90) z_angle = np.deg2rad(-90) rotation_matrix_y = np.array([ - [np.cos(y_angle), 0, np.sin(y_angle)], - [0, 1, 0 ], - [-np.sin(y_angle), 0, np.cos(y_angle)] + [np.cos(y_angle), 0, np.sin(y_angle)], + [0, 1, 0], + [-np.sin(y_angle), 0, np.cos(y_angle)] ]) rotation_matrix_z = np.array([ - [np.cos(z_angle), -np.sin(z_angle), 0], - [np.sin(z_angle), np.cos(z_angle), 0], - [0, 0, 1] + [np.cos(z_angle), -np.sin(z_angle), 0], + [np.sin(z_angle), np.cos(z_angle), 0], + [0, 0, 1] ]) points_np = points.cpu().numpy()
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L169
return cloud + class LidarDataset(DatasetTemplate): def __init__(self, dataset_cfg, class_names, training=True, logger=None, ext='.bin'): super().__init__( dataset_cfg=dataset_cfg, class_names=class_names, training=training, logger=logger ) + def main(args=None): rclpy.init(args=args)
src/perception/lidar_object_detection/lidar_object_detection/lidar_object_detection/lidar_object_detection_node.py#L182
node.destroy_node() rclpy.shutdown() + if __name__ == '__main__': main()
src/perception/lidar_object_detection/lidar_object_detection/launch/eve_launch.py#L2
from launch_ros.actions import Node from ament_index_python.packages import get_package_share_directory import os + def generate_launch_description(): ld = LaunchDescription()
Build Image and Run Unit Testing Suite (perception, lidar_object_detection)
buildx failed with: ERROR: failed to solve: process "/bin/sh -c pip3 install torch==1.13.1+cu116 torchvision==0.14.1+cu116 torchaudio==0.13.1 --extra-index-url https://download.pytorch.org/whl/cu116" did not complete successfully: exit code: 1
Build Image and Run Unit Testing Suite (perception, lidar_object_detection)
You are running out of disk space. The runner will stop working when the machine runs out of disk space. Free space left: 0 MB
Setup environment
Detected infrastructure changes
Setup environment
Using openpcdet-dan as the source branch
Setup environment
Using main as the target branch