EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TrackFindingOptions.cpp
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file TrackFindingOptions.cpp
1 // This file is part of the Acts project.
2 //
3 // Copyright (C) 2020 CERN for the benefit of the Acts project
4 //
5 // This Source Code Form is subject to the terms of the Mozilla Public
6 // License, v. 2.0. If a copy of the MPL was not distributed with this
7 // file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 
10 
12 
13 #include <string>
14 
15 #include <boost/program_options.hpp>
16 
20 
21  auto opt = desc.add_options();
22  opt("ckf-slselection-chi2max", value<double>()->default_value(15),
23  "Global criteria of maximum chi2 for CKF source link selection");
24  opt("ckf-slselection-nmax", value<size_t>()->default_value(10),
25  "Global criteria of maximum number of source link candidates on a "
26  "surface for CKF source link selection");
27 }
28 
31  const ActsExamples::Options::Variables& variables) {
32  auto chi2Max = variables["ckf-slselection-chi2max"].template as<double>();
33  auto nMax = variables["ckf-slselection-nmax"].template as<size_t>();
34 
35  // config is a GeometryHierarchyMap with just the global default
37  cfg.sourcelinkSelectorCfg = {
38  {Acts::GeometryIdentifier(), {chi2Max, nMax}},
39  };
40  return cfg;
41 }