MCPcopy Create free account
hub / github.com/comaps/comaps / main

Function main

libs/map/benchmark_tool/main.cpp:17–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

15DEFINE_bool(print_scales, false, "Print geometry scales for MWM and exit");
16
17int main(int argc, char ** argv)
18{
19 classificator::Load();
20
21 gflags::SetUsageMessage("MWM benchmarking tool");
22 if (argc < 2)
23 {
24 gflags::ShowUsageWithFlagsRestrict(argv[0], "main");
25 return 0;
26 }
27
28 gflags::ParseCommandLineFlags(&argc, &argv, false);
29
30 if (FLAGS_print_scales)
31 {
32 feature::DataHeader h(FLAGS_input);
33 cout << "Scales with geometry: ";
34 for (size_t i = 0; i < h.GetScalesCount(); ++i)
35 cout << h.GetScale(i) << " ";
36 cout << endl;
37 return 0;
38 }
39
40 if (!FLAGS_input.empty())
41 {
42 using namespace bench;
43
44 AllResult res;
45 RunFeaturesLoadingBenchmark(FLAGS_input, make_pair(FLAGS_lowS, FLAGS_highS), res);
46
47 res.Print();
48 }
49
50 return 0;
51}

Callers

nothing calls this directly

Calls 6

LoadFunction · 0.50
GetScalesCountMethod · 0.45
GetScaleMethod · 0.45
emptyMethod · 0.45
PrintMethod · 0.45

Tested by

no test coverage detected