Any way to load a partial scene? Just collision pieces?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By charlesrwest

Hello!

I’m working on a self driving sidewalk robot and trying to use Godot to generate synthetic training data for it. For my proof of concept, I’m just filling a 1 km x 1 km space with as many random 3d objects as I can get my hands on (100,000 instances of 80 or so objects right now) and using crude A* based navigation system to find a workable path for my simulated robot. My real robot will hopefully be able to use imitation learning to get better at dodging obstacles from the associated recordings.

The system is pretty much ready to go but I am running into a performance problem. I have a R* tree based method which determines which objects to load in a radius around the robot. That is working OK. What is having problems is the map scanning I do to determine passability for the A* navigation system.

I’m essentially doing a collision check with a cylinder at every point in a uniform grid across the entire map. This is complicated by the fact that I have to load/unload things as I do the check. With just 10 unique objects, it was taking 4 hours. With 80, it’s taking 4-5 days.

For scanning, all I really need is the parts of the object scenes which interact with physics. If I may ask, is there any way to just load those when I am scanning and load normally when I am rendering?

Thanks!