19#include <boost/serialization/access.hpp>
33 class alignas(VcMemAlign)
Setup {
34 friend class boost::serialization::access;
43 : fvMaterialLayers({})
44 , fField(
Field<T>(fldMode, EFieldType::Normal))
56 : fModuleIndexMap(other.fModuleIndexMap)
57 , fvMaterialLayers(other.fvMaterialLayers)
58 , fField(other.fField)
59 , fTarget(other.fTarget)
76 template<
class EDetID>
91 template<
class EDetID>
94 return fvMaterialLayers[fModuleIndexMap.LocalToGlobal(iDet, iLoc)];
101 int GetNofLayers()
const {
return static_cast<int>(fvMaterialLayers.size()); }
109 std::string
ToString(
int verbosity = 1,
int indentLevel = 0)
const;
112 template<
class Archive>
116 ar& fvMaterialLayers;
122 std::vector<MaterialMap> fvMaterialLayers{};
131 template<
class EDetID>
134 int iLayer{fModuleIndexMap.LocalToGlobal(iDet, iLoc)};
140 if (iLayer <
static_cast<int>(fvMaterialLayers.size() - 1)) {
141 fvMaterialLayers[iLayer + 1].Add(fvMaterialLayers[iLayer], utils::simd::Cast<T, float>(fTarget.GetZ()));
143 fvMaterialLayers.erase(fvMaterialLayers.begin() + iLayer);
146 fField.RemoveSlice(iLayer);
149 fModuleIndexMap.Disable(iDet, iLoc);
std::string ToString(ECbmModuleId modId)
Common constant definitions for the Kalman Filter library.
Magnetic field representation in KF (header)
A helper class to map external indices with the ones of KF-setup.
A target layer in the KF-setup (header)
std::vector with an additional utility set
Magnetic field manager class.
A map of station thickness in units of radiation length (X0) to the specific point in XY plane.
Maps local detector and station indices to the material maps and field slices.
Creates a valid initialized Setup instance.
KF-framework representation of the detector setup.
int GetNofLayers() const
Gets number of geometry layers.
const Target< T > & GetTarget() const
Gets target.
const ModuleIndexMap & GetIndexMap() const
Gets module index map.
~Setup()=default
Destructor.
Field< T > fField
Interpolated field (NOTE: maybe make optional)
Setup(const Setup< I > &other)
Copy constructor.
Setup & operator=(const Setup &other)=default
Move constructor.
const MaterialMap & GetMaterial(int iLayer) const
Gets material layer.
Setup(EFieldMode fldMode)
Constructor.
void serialize(Archive &ar, const unsigned int)
void DisableLayer(EDetID iDet, int iLoc)
Move assignment operator.
const Field< T > & GetField() const
Makes an instance of the field depending on the template parameter.
const MaterialMap & GetMaterial(EDetID iDet, int iLoc) const
Gets material layer from external indices.
Target< T > fTarget
Target layer.
A geometry layer in the target region.
EFieldMode
Enumiration for the magnetic field representation variants in the track fitting algorithm.