summaryrefslogtreecommitdiff
path: root/geom_bottleneck/bottleneck/src/bottleneck.cpp
diff options
context:
space:
mode:
authorArnur Nigmetov <a.nigmetov@gmail.com>2017-04-24 17:12:46 +0200
committerArnur Nigmetov <a.nigmetov@gmail.com>2017-04-24 17:12:46 +0200
commitad723189c90c37ffdba34c2db5c764ceb2192086 (patch)
tree03b976b2c47812087534a4a18cb17a1f69c778b7 /geom_bottleneck/bottleneck/src/bottleneck.cpp
parent24549c23156d612be2859583489f155bf8567008 (diff)
Verbose timing for bottleneck added
Timing info is printed, if VERBOSE_BOTTLENECK is #defined in def_debug_bt.h.
Diffstat (limited to 'geom_bottleneck/bottleneck/src/bottleneck.cpp')
-rw-r--r--geom_bottleneck/bottleneck/src/bottleneck.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/geom_bottleneck/bottleneck/src/bottleneck.cpp b/geom_bottleneck/bottleneck/src/bottleneck.cpp
index da0c425..f90e5c9 100644
--- a/geom_bottleneck/bottleneck/src/bottleneck.cpp
+++ b/geom_bottleneck/bottleneck/src/bottleneck.cpp
@@ -208,10 +208,15 @@ std::pair<double, double> bottleneckDistApproxIntervalHeur(DiagramPointSet& A, D
DiagramPointSet sampledA, sampledB;
sampleDiagramForHeur(A, sampledA);
sampleDiagramForHeur(B, sampledB);
- //std::cout << "A : " << A.size() << ", sampled: " << sampledA.size() << std::endl;
- //std::cout << "B : " << B.size() << ", sampled: " << sampledB.size() << std::endl;
+#ifdef VERBOSE_BOTTLENECK
+ std::cout << "A : " << A.size() << ", sampled: " << sampledA.size() << std::endl;
+ std::cout << "B : " << B.size() << ", sampled: " << sampledB.size() << std::endl;
+#endif
std::pair<double, double> initGuess = bottleneckDistApproxInterval(sampledA, sampledB, epsilon);
- //std::cout << "initial guess: " << initGuess.first << ", " << initGuess.second << std::endl;
+#ifdef VERBOSE_BOTTLENECK
+ std::cout << "initial guess with sampling: " << initGuess.first << ", " << initGuess.second << std::endl;
+ std::cout << "running on the original diagrams" << std::endl;
+#endif
return bottleneckDistApproxIntervalWithInitial(A, B, epsilon, initGuess);
}