BeautyMap icon indicating copy to clipboard operation
BeautyMap copied to clipboard

`IndexError: index 0 is out of bounds for axis 0 with size 0` with custom data

Open VRichardJP opened this issue 7 months ago • 8 comments

Hello!

I am trying to use BeautyMap on a custom map. I have a PCD map named data/raw_map.pcd and each frame composing it into files data/pcd/000000.pcd, data/pcd/000001.pcd, etc. Each frame has VIEWPOINT set correctly (e.g VIEWPOINT 5595.09 14392.2 819.099 0.799272 -0.014222 -0.00993263 0.600719).

The overall map is around 2.0GB. I have around 4000 frames of around 600KB each.

Based on you example I have tried the following command: python main.py --data_dir ./data/ --dis_range 40 --xy_resolution 1 --h_res 0.5.

Which leads to the following error:

$ python main.py --data_dir ./data/ --dis_range 40 --xy_resolution 1 --h_res 0.5
We will process the data in folder:  ./data/ 
[LOG] Min xyz: 4869.56689453125, 14181.6611328125, 775.1815795898438 
[LOG] Max/Min value on x: 1116.04150390625/0.0, y: 1298.7529296875/0.0
[LOG] Matrix order: 1299
Generating Map Binary tree: 100%|█████████████████████████| 447494/447494 [02:59<00:00, 2489.03it/s]
Processing Frames:   0%|                                                   | 0/3895 [00:00<?, ?it/s]
Traceback (most recent call last):
  File "main.py", line 136, in <module>
    fire.Fire(main)
  File "/home/vrichard/mambaforge/envs/beautymap/lib/python3.8/site-packages/fire/core.py", line 143, in Fire
    component_trace = _Fire(component, args, parsed_flag_args, context, name)
  File "/home/vrichard/mambaforge/envs/beautymap/lib/python3.8/site-packages/fire/core.py", line 477, in _Fire
    component, remaining_args = _CallAndUpdateTrace(
  File "/home/vrichard/mambaforge/envs/beautymap/lib/python3.8/site-packages/fire/core.py", line 693, in _CallAndUpdateTrace
    component = fn(*varargs, **kwargs)
  File "main.py", line 84, in main
    Qpts.generate_query_binary_tree(minz_matrix_roi)
  File "/home/vrichard/SLAM/tools/BeautyMap/lib/bee_tree.py", line 183, in generate_query_binary_tree
    idx = newidxy[ib][0]
IndexError: index 0 is out of bounds for axis 0 with size 0

Do you have any idea what is the issue here?

VRichardJP avatar Jul 12 '24 05:07 VRichardJP