16 #ifndef ICARUSCODE_GEOMETRY_ICARUSSTANDALONEGEOMETRYSETUP_H
17 #define ICARUSCODE_GEOMETRY_ICARUSSTANDALONEGEOMETRYSETUP_H
27 #include "fhiclcpp/types/Table.h"
28 #include "fhiclcpp/ParameterSet.h"
34 #include <type_traits>
37 namespace icarus::geo {
42 template <
typename Class,
typename =
void>
67 template <
typename ChannelMapClass,
typename... Args>
68 std::unique_ptr<::geo::GeometryCore>
72 (pset.get<fhicl::ParameterSet>(
"ChannelMapping"));
74 auto channelMap = std::make_unique<ChannelMapClass>
75 (config, std::forward<Args>(
args)...);
78 (pset, move(channelMap));
86 namespace icarus::geo::details {
89 template <
typename Class,
typename >
90 struct ConfigObjectMaker {
92 static fhicl::ParameterSet
const&
make(fhicl::ParameterSet
const& pset)
99 template <
typename Class>
106 {
return Parameters{ pset, std::set<std::string>{
"tool_type" } }(); }
113 namespace lar::standalone {
119 inline std::unique_ptr<geo::GeometryCore>
120 SetupGeometry<icarus::ICARUSChannelMapAlg>(fhicl::ParameterSet
const& pset)
121 {
return icarus::geo::SetupICARUSGeometry<icarus::ICARUSChannelMapAlg>(pset); }
131 #endif // ICARUSCODE_GEOMETRY_ICARUSSTANDALONEGEOMETRYSETUP_H
double std(const std::vector< short > &wf, const double ped_mean, size_t start, size_t nsample)
std::unique_ptr<::geo::GeometryCore > SetupICARUSGeometry(fhicl::ParameterSet const &pset, Args &&...args)
Initialization of geometry with ICARUS specific conventions.
Channel mapping algorithms for ICARUS detector.
typename Class::Config Config
Utilities for one-line geometry initialization.
static Config make(fhicl::ParameterSet const &pset)
fhicl::Table< Config > Parameters
static fhicl::ParameterSet const & make(fhicl::ParameterSet const &pset)
Creates a configuration object for Class from a parameter set.
std::unique_ptr< geo::GeometryCore > SetupGeometryWithChannelMapping(fhicl::ParameterSet const &pset, std::unique_ptr< geo::ChannelMapAlg > channelMap)
Initializes a LArSoft geometry object.
typename make_void< Ts...>::type void_t