ethz-asl / voxgraph

Voxblox-based Pose graph optimization
BSD 2-Clause "Simplified" License
514 stars 69 forks source link

tf error with voxgraph but not voxblox #49

Open anujchadha284 opened 3 years ago

anujchadha284 commented 3 years ago

Hi,

I have used lidar data to generate a mesh in voxblox, using a world frame and a lidar frame but when I use this same frame in voxgraph, I get this error: [[ WARN] [1610639130.678306094, 1397.115659165]: Waited 2.000s, but still could not get the TF from os_sensor to world [ WARN] [1610639130.678406105, 1397.115659165]: Skipping pointcloud since the poses at time 1397.862524530 could not be looked up.

It seems to work in voxblox and I can display the pointcloud in Rviz - could you suggest any corrections for this?

This is how I am using the config file:

input_odom_frame: world input_base_link_frame: os_sensor output_mission_frame: mission output_odom_frame: world output_base_link_frame: os_sensor output_sensor_frame: os_lidar

Thanks!

anujchadha284 commented 3 years ago

Hi - I managed to fix this issue by speeding up the bag I was using - it was running at 0.1 speed and now I am running it at 0.5 speed. One issue I am getting is the voxgraph mapper node dies when I make the voxel size below 0.2 - is it not built to go that low? Thanks!

victorreijgwart commented 3 years ago

Hi @anujchadha284, glad to hear you found a solution for the TF error. I personally have had good results with voxels down to 0.05m with reasonably sized outdoor environments, or even 0.02m if it's a single room. This takes quite a bit of RAM though, and if your machine is about to run out of memory the kernel often kills the offending process (in this case voxgraph) to keep your computer from freezing. How much RAM do you have on your machine? Are you using custom data and settings? If so, what does your environment look like, how long is the rosbag, and what settings are you using for the TSDF integrator?

anujchadha284 commented 3 years ago

Okay - I have a big dataset and have 32GB RAM on my machine and currently am running it with 0.1m voxels with 20m long rays. I am noticing after running it for a bit , it starts to say no convergence - what possible solutions are there for that?

On Sun, 17 Jan 2021 at 10:53, Victor Reijgwart notifications@github.com wrote:

Hi @anujchadha284 https://github.com/anujchadha284, glad to hear you found a solution for the TF error. I personally have had good results with voxels down to 0.05m with reasonably sized outdoor environments, or even 0.02m if it's a single room. This takes quite a bit of RAM though, and if your machine is about to run out of memory the kernel often kills the offending process (in this case voxgraph) to keep your computer from freezing. How much RAM do you have on your machine? Are you using custom data and settings? If so, what does your environment look like, how long is the rosbag, and what settings are you using for the TSDF integrator?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ethz-asl/voxgraph/issues/49#issuecomment-761833828, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABUJO4FLPD4DTBDYW34TJ53S2MBYLANCNFSM4WCSTCJA .

victorreijgwart commented 3 years ago

These settings sound reasonable, and 32GB of RAM should be enough. When you said earlier that the voxgraph node dies, did you mean that its Linux process stops or just that it says "no convergence" on the command line? In the default settings, the pose graph optimization is configured to stop taking further steps once a total of 4 seconds have passed. When the submaps get large and numerous, the individual optimization steps take longer and the convergence criteria might not always be met before the time limit is reached. When this happens, the results of the last successful optimization step are applied. Since the optimization runs periodically, the solution will be improved further in the next cycle. If you do not care about real-time performance, you could change the optimization settings here and configure voxgraph to pause your rosbag while the optimization is running here.

anujchadha284 commented 3 years ago

Thanks for the quick reply! So when I have the voxel size too small, the linux process stops. However, when I changed the voxel size to higher, this is when I noticed the lack of convergence. I changed the optimization settings but I am noticing that some part of my mesh is missing when I run the service call to save the combined mesh. Since we do not care about real-time performance, what settings do you recommend for mapping out a big area? Should I increase the threads used as well? Also, the service call seems to take a while to complete - is this normal?

Thanks!

On Mon, 18 Jan 2021 at 10:00, Victor Reijgwart notifications@github.com wrote:

These settings sound reasonable, and 32GB of RAM should be enough. When you said earlier that the voxgraph node dies, did you mean that its Linux process stops or just that it says "no convergence" on the command line? In the default settings, the pose graph optimization is configured to stop taking further steps once a total of 4 seconds have passed. When the submaps get large and numerous, the individual optimization steps take longer and the convergence criteria might not always be met before the time limit is reached. When this happens, the results of the last successful optimization step are applied. Since the optimization runs periodically, the solution will be improved further in the next cycle. If you do not care about real-time performance, you could change the optimization settings here https://github.com/ethz-asl/voxgraph/blob/master/voxgraph/src/backend/pose_graph.cpp#L95 and configure voxgraph to pause your rosbag while the optimization is running here https://github.com/ethz-asl/voxgraph/blob/master/voxgraph/src/backend/pose_graph.cpp .

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ethz-asl/voxgraph/issues/49#issuecomment-762303524, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABUJO4HJJTJ53FHLJP3YXULS2REKHANCNFSM4WCSTCJA .

anujchadha284 commented 3 years ago

Hi - so my rosbag is 1074 seconds long and I am running it at 0.05s speed - I am noticing that it works well initially, but after a bit the optimization step takes too long to complete such that when it reaches the next one, I am getting a warning in the terminal that the previous optimization step is not complete. What settings would you recommend for a huge dataset, with a detailed pointcloud. Preferably I would like the voxel size to be <0.2m and a ray length of 35-50m. I would also like the voxels to be smooth rather than jagged. Are there any template settings for the config.yaml you would recommend? I previously tried 0.05m with 50m rays in voxblox and it seemed to work well (RAM was eventually an issue but that's okay) but with the addition of the optimization in voxgraph, I am getting some issues with the map being filled out. Thanks!