diff --git a/DataStructures/NNGrid.h b/DataStructures/NNGrid.h index 61e3e9d30..fb79d3400 100644 --- a/DataStructures/NNGrid.h +++ b/DataStructures/NNGrid.h @@ -329,14 +329,14 @@ public: } } - // INFO("startcoord: " << smallestEdge.startCoord << ", tgtcoord" << smallestEdge.targetCoord << "result: " << newEndpoint); - // INFO("length of old edge: " << LengthOfVector(smallestEdge.startCoord, smallestEdge.targetCoord)); - // INFO("Length of new edge: " << LengthOfVector(smallestEdge.startCoord, newEndpoint)); - // assert(!resultNode.isBidirected || (resultNode.weight1 == resultNode.weight2)); - // if(resultNode.weight1 != resultNode.weight2) { - // INFO("-> Weight1: " << resultNode.weight1 << ", weight2: " << resultNode.weight2); - // INFO("-> node: " << resultNode.edgeBasedNode << ", bidir: " << (resultNode.isBidirected ? "yes" : "no")); - // } +// INFO("startcoord: " << smallestEdge.startCoord << ", tgtcoord" << smallestEdge.targetCoord << "result: " << newEndpoint); +// INFO("length of old edge: " << LengthOfVector(smallestEdge.startCoord, smallestEdge.targetCoord)); +// INFO("Length of new edge: " << LengthOfVector(smallestEdge.startCoord, newEndpoint)); +// assert(!resultNode.isBidirected() || (resultNode.weight1 == resultNode.weight2)); +// if(resultNode.weight1 != resultNode.weight2) { +// INFO("-> Weight1: " << resultNode.weight1 << ", weight2: " << resultNode.weight2); +// INFO("-> node: " << resultNode.edgeBasedNode << ", bidir: " << (resultNode.isBidirected() ? "yes" : "no")); +// } double ratio = std::min(1., LengthOfVector(smallestEdge.startCoord, newEndpoint)/LengthOfVector(smallestEdge.startCoord, smallestEdge.targetCoord) ); assert(ratio >= 0 && ratio <=1); @@ -547,6 +547,11 @@ private: if(!localStream.get() || !localStream->is_open()) { localStream.reset(new std::ifstream(iif.c_str(), std::ios::in | std::ios::binary)); } + if(!localStream->good()) { + localStream->clear(std::ios::goodbit); + DEBUG("Resetting stale filestream"); + } + localStream->seekg(startIndexInFile); localStream->read((char*) &cellIndex[0], 32*32*sizeof(unsigned)); assert(cellMap.find(fileIndex) != cellMap.end()); diff --git a/Plugins/ViaRoutePlugin.h b/Plugins/ViaRoutePlugin.h index 4172214b0..99bb8f37a 100644 --- a/Plugins/ViaRoutePlugin.h +++ b/Plugins/ViaRoutePlugin.h @@ -140,7 +140,7 @@ public: distance = searchEngine->ComputeRoute(segmentPhantomNodes, path); if(INT_MAX == distance ) { - INFO( "Error occurred, single path not found" ); + DEBUG( "Error occurred, single path not found" ); } //put segments at correct position of routes raw data