sloam icon indicating copy to clipboard operation
sloam copied to clipboard

free(): invalid pointer ERROR

Open nvhungv2k opened this issue 1 year ago • 9 comments
trafficstars

Hello everyone, I built SLOAM with debug option to debug it with GDB: catkin build -DCMAKE_BUILD_TYPE=Debug And then, I was running SLOAM on: ubuntu 20.04; ros noetic: roslaunch sloam run_sim.launch But when LiDAR information came up, it emitted the fatal error: free(): invalid pointer I debugged it with GDB by add launch-prefix="xterm -fa 'Monospace' -fs 14 -e gdb --args" to sloam node in sloam.launch as following: ... <node pkg="sloam" type="sloam_node" name="sloam" output="screen" launch-prefix="xterm -fa 'Monospace' -fs 14 -e gdb --args"> ... Through debugging I found out, this error comes from Segmentation::run(..) function, at line 374, in inference.cpp file it is so strange that image As above figure, when I am at line 445, only with command line: if(_verbose) the next line should has been line 446 (if _verbose is true) or 448 (end of run(..) function), but it is line 421 (marked red in figure) Continuing to debug, next line is decreasing (421 -> 420 -> ... -> 385), not increasing I still DID NOT figure out why the program run so

nvhungv2k avatar Jun 20 '24 08:06 nvhungv2k

what do the clouds look like for you when you save them as .pcd? I never hit that specific error... try writing some prints to check that the model tensor input dimensions match those of the cloud vector. as long as the stable_bdarknet.onnx and the zamboni.bag or whatever are still the same as in the OG branch, then you should be fine.

mycochang avatar Jun 21 '24 16:06 mycochang

I converted pointcloud to *pcd and then viewed it using pcl_ros and pcl_viewer (a component of pcl-tools) respectively. The result is as follow: image As I described above, why the program Segmentation::run(..) function, at line 374, in inference.cpp file run decreasingly

nvhungv2k avatar Jun 22 '24 09:06 nvhungv2k

  1. use: https://www.cloudcompare.org/ for many reasons ;)

  2. hard to tell from only top-down-view but IMO your screenshot does NOT look like the VLP-16 used in run_sim inputs:

  3. I can confirm the current 404 status on the .onnx and .bag GDrive links. I don't think those files are mine to share, and I trust that the authors will handle it. I used a labeling tool and rangenet++ to make my own model, which you SHOULD do, for whatever LiDAR you will use in field applications, because:

  4. if anyone else reading/trying has already figured out how to make the inference.cpp &/ trellis.cpp more sensor-agnostic, let us know! :)

mycochang avatar Jun 22 '24 14:06 mycochang

  1. Thanks for your sharing
  2. I think run_sim input can be any kind of LiDAR sensor (not necessarily is VLP-16), doesn't it? I do not see any snippet in SLOAM indicated that it fixed the kind of LiDAR, if any, please show me
  3. I already have been trying to create my own model. Firstly, I used semantickitti dataset as rangenet++. But with my current computer is RAM 32G, CPU 16 intel cores i7, GPU Nvidia Quadro T1000 4GB. As soon as running training, it overflowed RAM memory and then computer hang
  4. I hope anyone else already has done...

nvhungv2k avatar Jun 22 '24 15:06 nvhungv2k

Hi @nvhungv2k, Have you successfully trained your own model?

li1997522 avatar Nov 11 '24 07:11 li1997522

  1. use: https://www.cloudcompare.org/ for many reasons ;)
  2. hard to tell from only top-down-view but IMO your screenshot does NOT look like the VLP-16 used in run_sim inputs:
  3. I can confirm the current 404 status on the .onnx and .bag GDrive links. I don't think those files are mine to share, and I trust that the authors will handle it. I used a labeling tool and rangenet++ to make my own model, which you SHOULD do, for whatever LiDAR you will use in field applications, because:
  4. if anyone else reading/trying has already figured out how to make the inference.cpp &/ trellis.cpp more sensor-agnostic, let us know! :)

Hi @mycochang , Regarding point 3, a. Would the default semantic kitti dataset and labels not work as is for training the model? Why do we need to label it again -- can we not use the same classifiers? b. Also, will it not work if we change our lidar sensor to be different from Velodyne? Will the semantic kitti dataset not work for us then?

I am fairly new to AI, so please don't mind if some of the questions are too basic. :)

sachman avatar Apr 21 '25 02:04 sachman

Check our fork if you want to know what the hesai xt32 compatibility "patch" looks like... It... "works"

We were simply interested in outdoor data scenarios more complex than kitti, which is urban.

The biggest challenge you'll have will be making RangeNet++ work on a local machine with appropriate CUDA and whatnot as a test case before migrating to HPC.

mycochang avatar May 01 '25 08:05 mycochang

Hi. I could not find your fork -- could you point me to it?

EDITL: Found it: https://github.com/unibz-first/sloam

Thanks!

sachman avatar May 16 '25 18:05 sachman

https://github.com/unibz-first/sloam

Sent from Outlook for iOShttps://aka.ms/o0ukef


From: sachman @.> Sent: Friday, May 16, 2025 8:50:35 PM To: KumarRobotics/sloam @.> Cc: Chang Michael Reynolds (Student ENG 22) @.>; Mention @.> Subject: Re: [KumarRobotics/sloam] free(): invalid pointer ERROR (Issue #6)

[https://avatars.githubusercontent.com/u/17062337?s=20&v=4]sachman left a comment (KumarRobotics/sloam#6)https://github.com/KumarRobotics/sloam/issues/6#issuecomment-2887452964

Hi. I could not find your fork -- could you point me to it?

— Reply to this email directly, view it on GitHubhttps://github.com/KumarRobotics/sloam/issues/6#issuecomment-2887452964, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAMNFIS42BE5X2EJNFWRU7L26YXPXAVCNFSM6AAAAAB3QNB7YKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQOBXGQ2TEOJWGQ. You are receiving this because you were mentioned.Message ID: @.***>

mycochang avatar May 19 '25 14:05 mycochang