Will increase route.init_threads speed up the building street network?


#1

will increase route.init_threads speed up the building street network?

got this error when set the init_threads to 4

ors-core | 20 Dec 15:02:03 ERROR [routing.RoutingProfileManager] - java.util.concurrent.ExecutionException: java.lang.RuntimeException: To avoid reading partial data we need to obtain the read lock but it failed. In data/graphs/vehicles-car
ors-core | java.util.concurrent.ExecutionException: java.lang.RuntimeException: To avoid reading partial data we need to obtain the read lock but it failed. In data/graphs/vehicles-car


#2

Hi @xiatao123

the init_threads option basically tells the system how many threads to use for building profiles, but each profile can only be built on one thread. So if you are only building one profile, then increasing the thread_count would not make any difference in terms of speed.

The error message you see normally means that the graph file is already open by another process, but that should not be due to the init_threads and is most likely that there is another instance of openrouteservice still running when you try to build. To be safe though you should limit the umber of threads to the number of profiles being built, and ensure that each profile only appears once in the app.config

Hope that helps