GraphHopper.com | Forum | GitHub | Maps | Blog

“Connection between locations not found”


#1

I am using GraphHopper Core on a desktop doing offline routing for car. After testing more than 9000 trips I tried, 7 of them show up with “Connection between locations not found” error message. However, those trips have no problem getting driving route on GraphHopper Map.
I found this old article on the forum 0.5.0: Connection between locations not found, which suggested playing with the settings “prepare.minOnewayNetworkSize=200” or decrease “prepare.minNetworkSize”, but that did not work for me.
One example is from (30.263,-97.794) to (30.265,-97.736):
https://graphhopper.com/maps/?point=30.263%2C-97.794&point=30.265%2C-97.736&locale=en-US&vehicle=car&weighting=fastest&elevation=true&use_miles=false&layer=Omniscale
I believe it is something about the origin (30.263,-97.794), since I have another trip with the same origin showing the same error message. Any suggestion?

Ps. Here is some key lines from my code:

String drivingWeight = “fastest”; //shortest, fastest, short_fastest

// Create Gaphhopper instance
GraphHopper hopper;
hopper = new GraphHopperOSM().forDesktop();
hopper.setDataReaderFile("…/texas-latest.osm.pbf");
hopper.setGraphHopperLocation("…/gh-car_"+drivingWeight);
hopper.setEncodingManager(new EncodingManager(“car”));
hopper.getCHFactoryDecorator().setWeightingsAsStrings(drivingWeight);

GHRequest request = new GHRequest(origLat, origLng, destLat, destLng);
request.setWeighting(drivingWeight);
request.setVehicle(“car”);
GHResponse route = hopper.route(request);


#2

“prepare.minOnewayNetworkSize=200” or decrease “prepare.minNetworkSize”, but that did not work for me.

Try increasing them.

Until 0.10 the settings are:

prepare.min_network_size=200
prepare.min_one_way_network_size=200

From 0.11 the settings are:

prepare.min_network_size: 200
prepare.min_one_way_network_size: 200


#3

I have the same problem with graphs generated from osm data, in this website seems there is the same problem, for example
https://graphhopper.com/maps/?point=35.734994%2C51.402969&point=36.058721%2C51.526794&locale=de-DE&vehicle=car&weighting=fastest&elevation=true&use_miles=false&layer=Omniscale

what is the best way to insure that we can have at least one possible route?is it even possible?


#4

This is a different issue (Cannot find point 1). In such a case please create new topics.


#5

This setting was the one I tried by adding hopper.setMinNetworkSize(200, 200) (I believe this is doing the same thing as you suggested?), but the problem remains.


#6

As I said: try increasing it e.g. to 600.


#7

Tried up to 20000 but still no luck (still the same 7 routes without connection), is it possible to be some other issue here?