PRBonn / lidar-bonnetal

Semantic and Instance Segmentation of LiDAR point clouds for autonomous driving
http://semantic-kitti.org
MIT License
915 stars 204 forks source link

IndexError: index -2147483648 is out of bounds for axis 0 with size 64 #95

Closed Trexzhou closed 12 months ago

Trexzhou commented 2 years ago

Hi, thanks for your excellent works! But when I try to train by run "./train.py -d /path/to/dataset -ac /config/arch/squeezesegV2.yaml -l /path/to/log", an IndexError was caught, see: 111 I have check the variable "proj_y", it does have a large number. I want to know what's the problem? Thanks a lots!

jbehley commented 2 years ago

sorry for the late reply. it's hard to debug what it's happening there, but something in the projection does produce a strange y coordinate. I would try to check if all points are in bounds and if you need to modify the field of view (fov) of the sensor. I guess that you try to use your own dataset?

dl19940602 commented 2 years ago

hello, I met the same problem before, -2147483648 occur may due to the NAN value in lidar points, you may try to add below code in line 116 and line 119 in common/laserscan.py self.points = np.nan_to_num(self.points) may it help you!

jbehley commented 2 years ago

Does this solve your issue, @Trexzhou?

xdtzzz commented 2 years ago

Hi, @Trexzhou , did you sovle your problem? I met the same problem like you, can you help me? @dl19940602 ,thanks your reply, I tried your method, but it doesn't work

rohithsaro commented 1 year ago

@jbehley @dl19940602 @Trexzhou @xdtzzz @l9761116 Did anyone solve this issue ? :)

rohithsaro commented 1 year ago

Screenshot_2022-10-27_12-04-57

May have found the issue. So i used a custom dataset and within said dataset, there seems to be a point at the center of the frame with values 0 in x,y,z coordinate. The Z value being zero at this coordinate interferes with the pitch calculation ( pitch = np.arcsin(scan_z , depth) resulting 0/0 ) in laserscan.py. Also make sure your dataset is in the right fixed frame when inferring.

You can correct me if i am wrong.

Best regards,

Rohith.