All of a sudden, when trying to reprocess new-zealand-latest.osm.pbf from Geofabrik server I receive errors.
It has worked previously. Anyone have any insight?
I have tried updating my srtm files to no avail.
I have removed CH processing but get the same error.
I have removed the association for elevation data and it works.
I received this error randomly - Couldn't process file C:\Users\sc\Desktop\DRST\new-zealand-latest.osm.pbf, error: Can't decode srtm_71_22.tif
I get the srtm data from https://srtm.csi.cgiar.org/srtmdata/
Any idea how to fix this?
Using Graphhopper 2.1
EncodingManager encodingManager = EncodingManager.create(FlagEncoderFactory.FOOT + "|block_private=false," + FlagEncoderFactory.CAR + "," + FlagEncoderFactory.MOTORCYCLE + "|turn_costs=true");
String locationGrapphopperFiles = GeneralFunctions.graphhopperFileLocation();
String locationRoutingFile = GeneralFunctions.routingFileLocation();
// Exclude footways, pedestrian areas, stairs from paxster profile
CustomModel model = new CustomModel();
HashMap map = new HashMap();
map.put("footway", 0);
map.put("pedestrian", 0);
map.put("steps", 0);
map.put("service", 1.0);
map.put("path", 0);
map.put("track", 0);
model.getPriority().put("road_class", map);
graphHopper = new GraphHopperOSM()
.setGraphHopperLocation(locationGrapphopperFiles)
.setEncodingManager(encodingManager)
.setDataReaderFile(locationRoutingFile)
.setElevation(true).setAllowWrites(true)
.setMemoryMapped()
.setElevationProvider(new CGIARProvider(System.getProperty("user.home")+File.separator+"srtm"+File.separator))
.setProfiles(Arrays.asList(
new Profile("foot").setVehicle("foot").setWeighting("fastest"),
new Profile("car").setVehicle("car").setWeighting("fastest"),
new Profile("rural").setVehicle("motorcycle").setWeighting("fastest").setTurnCosts(true).putHint("u_turn_costs", 3),
new CustomProfile("paxster").setCustomModel(model).setVehicle("foot").setWeighting("custom")))
.forDesktop();
ArrayList<CHProfile> chProfiles = new ArrayList();
chProfiles.add(new CHProfile("car"));
chProfiles.add(new CHProfile("foot"));
chProfiles.add(new CHProfile("rural"));
chProfiles.add(new CHProfile("paxster"));
graphHopper.getCHPreparationHandler().setCHProfiles(chProfiles);
graphHopper.setMemoryMapped();
graphHopper.importOrLoad();
Couldn’t process file C:\Users\sc\drst\new-zealand-latest.osm.pbf, error: java.net.SocketTimeoutException: Read timed out
Exception in thread "PBF Reader" java.lang.RuntimeException: Unable to read PBF file.
at com.graphhopper.reader.osm.pbf.PbfReader.run(PbfReader.java:50)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.RuntimeException: java.lang.InterruptedException
at com.graphhopper.reader.osm.OSMInputFile.process(OSMInputFile.java:253)
at com.graphhopper.reader.osm.pbf.PbfDecoder.sendResultsToSink(PbfDecoder.java:96)
at com.graphhopper.reader.osm.pbf.PbfDecoder.processBlobs(PbfDecoder.java:151)
at com.graphhopper.reader.osm.pbf.PbfDecoder.run(PbfDecoder.java:162)
at com.graphhopper.reader.osm.pbf.PbfReader.run(PbfReader.java:47)
... 1 more
Caused by: java.lang.InterruptedException
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.reportInterruptAfterWait(AbstractQueuedSynchronizer.java:2014)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2048)
at java.util.concurrent.LinkedBlockingQueue.put(LinkedBlockingQueue.java:350)
at com.graphhopper.reader.osm.OSMInputFile.process(OSMInputFile.java:251)
... 5 more
After error I get the following in the folders;
srtm processing
GH Folder