 |
ATLAS Offline Software
|
#include <ClusterMakerTool.h>
|
| ClusterMakerTool (const std::string &type, const std::string &name, const IInterface *parent) |
|
| ~ClusterMakerTool ()=default |
|
StatusCode | initialize () |
|
PixelCluster | pixelCluster (const Identifier &clusterID, const Amg::Vector2D &localPos, std::vector< Identifier > &&rdoList, const int lvl1a, std::vector< int > &&totList, const SiWidth &width, const InDetDD::SiDetectorElement *element, bool ganged, int errorStrategy, const PixelID &pixelID, bool split, double splitProb1, double splitProb2, const PixelChargeCalibCondData *calibData, const PixelCalib::PixelOfflineCalibData *offlineCalibData, const EventContext &ctx) const |
|
xAOD::PixelCluster * | xAODpixelCluster (xAOD::PixelCluster &cluster, const Amg::Vector2D &localPos, const std::vector< Identifier > &rdoList, const int lvl1a, const std::vector< int > &totList, const SiWidth &width, const InDetDD::SiDetectorElement *element, bool ganged, int errorStrategy, const PixelID &pixelID, bool split, double splitProb1, double splitProb2, const PixelChargeCalibCondData *calibData, const PixelCalib::PixelOfflineCalibData *offlineCalibData, const EventContext &ctx) const |
|
SCT_Cluster | sctCluster (const Identifier &clusterID, const Amg::Vector2D &localPos, std::vector< Identifier > &&rdoList, const SiWidth &width, const InDetDD::SiDetectorElement *element, int errorStrategy) const |
|
ServiceHandle< StoreGateSvc > & | evtStore () |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | evtStore () const |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | detStore () const |
| The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
virtual StatusCode | sysInitialize () override |
| Perform system initialization for an algorithm. More...
|
|
virtual StatusCode | sysStart () override |
| Handle START transition. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. More...
|
|
Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T, V, H > &t) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") |
| Declare a new Gaudi property. More...
|
|
void | updateVHKA (Gaudi::Details::PropertyBase &) |
|
MsgStream & | msg () const |
|
MsgStream & | msg (const MSG::Level lvl) const |
|
bool | msgLvl (const MSG::Level lvl) const |
|
|
template<typename ClusterType , typename IdentifierVec , typename ToTList > |
ClusterType | makePixelCluster (const Identifier &clusterID, const Amg::Vector2D &localPos, IdentifierVec &&rdoList, const int lvl1a, ToTList &&totList, const SiWidth &width, const InDetDD::SiDetectorElement *element, bool ganged, int errorStrategy, const PixelID &pixelID, bool split, double splitProb1, double splitProb2, const PixelChargeCalibCondData *calibData, const PixelCalib::PixelOfflineCalibData *offlineCalibData, const EventContext &ctx, xAOD::PixelCluster *cluster=nullptr) const |
|
double | getPixelCTBPhiError (int layer, int phi, int PhiClusterSize) const |
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKey> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &) |
| specialization for handling Gaudi::Property<SG::VarHandleBase> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &) |
| specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
|
|
Definition at line 56 of file ClusterMakerTool.h.
◆ StoreGateSvc_t
◆ ClusterMakerTool()
InDet::ClusterMakerTool::ClusterMakerTool |
( |
const std::string & |
type, |
|
|
const std::string & |
name, |
|
|
const IInterface * |
parent |
|
) |
| |
◆ ~ClusterMakerTool()
InDet::ClusterMakerTool::~ClusterMakerTool |
( |
| ) |
|
|
default |
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
253 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
229 return PBASE::declareProperty(
name,hndl,
doc);
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
338 return PBASE::declareProperty(
name, property,
doc);
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
◆ getPixelCTBPhiError()
double InDet::ClusterMakerTool::getPixelCTBPhiError |
( |
int |
layer, |
|
|
int |
phi, |
|
|
int |
PhiClusterSize |
|
) |
| const |
|
private |
Definition at line 582 of file ClusterMakerTool.cxx.
592 if(phiClusterSize > 3)
return 14.6*
micrometer;
594 if(
layer == 0 && phi == 0)
return sigmaL0Phi0[phiClusterSize-1];
595 if(
layer == 1 && phi == 0)
return sigmaL1Phi0[phiClusterSize-1];
596 if(
layer == 2 && phi == 0)
return sigmaL2Phi0[phiClusterSize-1];
597 if(
layer == 0 && phi == 1)
return sigmaL0Phi1[phiClusterSize-1];
598 if(
layer == 1 && phi == 1)
return sigmaL1Phi1[phiClusterSize-1];
599 if(
layer == 2 && phi == 1)
return sigmaL2Phi1[phiClusterSize-1];
603 <<
layer <<
" and phi = " << phi);
◆ initialize()
StatusCode InDet::ClusterMakerTool::initialize |
( |
| ) |
|
◆ inputHandles()
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ interfaceID()
static const InterfaceID& InDet::ClusterMakerTool::interfaceID |
( |
| ) |
|
|
inlinestatic |
◆ makePixelCluster()
template<typename ClusterType , typename IdentifierVec , typename ToTList >
ClusterType InDet::ClusterMakerTool::makePixelCluster |
( |
const Identifier & |
clusterID, |
|
|
const Amg::Vector2D & |
localPos, |
|
|
IdentifierVec && |
rdoList, |
|
|
const int |
lvl1a, |
|
|
ToTList && |
totList, |
|
|
const SiWidth & |
width, |
|
|
const InDetDD::SiDetectorElement * |
element, |
|
|
bool |
ganged, |
|
|
int |
errorStrategy, |
|
|
const PixelID & |
pixelID, |
|
|
bool |
split, |
|
|
double |
splitProb1, |
|
|
double |
splitProb2, |
|
|
const PixelChargeCalibCondData * |
calibData, |
|
|
const PixelCalib::PixelOfflineCalibData * |
offlineCalibData, |
|
|
const EventContext & |
ctx, |
|
|
xAOD::PixelCluster * |
cluster = nullptr |
|
) |
| const |
|
private |
Definition at line 195 of file ClusterMakerTool.cxx.
220 throw std::runtime_error(
"Dynamic cast failed for design in ClusterMakerTool.cxx");
222 int rowMin = design->rows();
224 int colMin = design->columns();
226 float qRowMin = 0;
float qRowMax = 0;
227 float qColMin = 0;
float qColMax = 0;
228 std::vector<float> chargeList;
229 int nRDO=rdoList.size();
231 chargeList.reserve(nRDO);
232 for (
int i=0;
i<nRDO;
i++) {
243 charge = ToT/8.0*(8000.0-1200.0)+1200.0;
245 chargeList.push_back(
charge);
249 for (
int i=0;
i<nRDO;
i++) {
254 if (calibData) {
charge=chargeList[
i]; }
270 if (col == colMin) qColMin +=
charge;
276 if (col == colMax) qColMax +=
charge;
288 if(qRowMin+qRowMax > 0) omegax = qRowMax/
float(qRowMin+qRowMax);
289 if(qColMin+qColMax > 0) omegay = qColMax/
float(qColMin+qColMax);
298 double Ax[3] = {
T(0,0),
T(1,0),
T(2,0)};
299 double Ay[3] = {
T(0,1),
T(1,1),
T(2,1)};
300 double R [3] = {
T(0,3),
T(1,3),
T(2,3)};
303 Amg::Vector3D globalPos(M[0]*Ax[0]+M[1]*Ay[0]+R[0],M[0]*Ax[1]+M[1]*Ay[1]+R[1],M[0]*Ax[2]+M[1]*Ay[2]+R[2]);
309 errorMatrix.setIdentity();
314 double eta = std::abs(globalPos.eta());
315 double zPitch =
width.z()/colRow.y();
320 throw std::runtime_error(
"Wrong helper type in ClusterMakerTool.cxx.");
323 int layer =
pid->layer_disk(clusterID);
325 switch (errorStrategy){
339 if (offlineCalibData) {
344 errorMatrix.fillSymmetric(0,0,
pow(phiError,2));
351 errorMatrix.fillSymmetric(0,0,square(phiError));
352 errorMatrix.fillSymmetric(1,1,square(
etaError));
357 errorMatrix.fillSymmetric(1,1,square(zPitch)*
ONE_TWELFTH);
376 static_assert(std::is_same_v<ClusterType, PixelCluster> ||
377 std::is_same_v<std::remove_pointer_t<ClusterType>,
379 "Not an InDet::PixelCluster or xAOD::PixelCluster");
381 return newInDetpixelCluster(newClusterID, locpos,
383 std::forward<IdentifierVec>(rdoList),
385 std::forward<ToTList>(totList),
386 std::move(chargeList),
389 std::move(errorMatrix),
396 return AddNewxAODpixelCluster(*cluster)(newClusterID,
399 std::forward<IdentifierVec>(rdoList),
401 std::forward<ToTList>(totList),
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ pixelCluster()
PixelCluster InDet::ClusterMakerTool::pixelCluster |
( |
const Identifier & |
clusterID, |
|
|
const Amg::Vector2D & |
localPos, |
|
|
std::vector< Identifier > && |
rdoList, |
|
|
const int |
lvl1a, |
|
|
std::vector< int > && |
totList, |
|
|
const SiWidth & |
width, |
|
|
const InDetDD::SiDetectorElement * |
element, |
|
|
bool |
ganged, |
|
|
int |
errorStrategy, |
|
|
const PixelID & |
pixelID, |
|
|
bool |
split, |
|
|
double |
splitProb1, |
|
|
double |
splitProb2, |
|
|
const PixelChargeCalibCondData * |
calibData, |
|
|
const PixelCalib::PixelOfflineCalibData * |
offlineCalibData, |
|
|
const EventContext & |
ctx |
|
) |
| const |
◆ renounce()
◆ renounceArray()
◆ sctCluster()
Definition at line 503 of file ClusterMakerTool.cxx.
520 errorMatrix.setIdentity();
526 switch (errorStrategy){
538 else if(colRow.x() == 2){
552 else if(colRow.x() == 2){
569 double v0 = (errorMatrix)(0,0)*
w*
w;
570 double v1 = (errorMatrix)(1,1);
571 errorMatrix.fillSymmetric(0,0,cs2*
v0+sn2*v1);
572 errorMatrix.fillSymmetric(0,1,sn*sqrt(cs2)*(
v0-v1));
573 errorMatrix.fillSymmetric(1,1,sn2*
v0+cs2*v1);
576 return SCT_Cluster(clusterID, locpos, std::move(rdoList),
width, element, std::move(errorMatrix));
◆ sysInitialize()
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ xAODpixelCluster()
xAOD::PixelCluster * InDet::ClusterMakerTool::xAODpixelCluster |
( |
xAOD::PixelCluster & |
cluster, |
|
|
const Amg::Vector2D & |
localPos, |
|
|
const std::vector< Identifier > & |
rdoList, |
|
|
const int |
lvl1a, |
|
|
const std::vector< int > & |
totList, |
|
|
const SiWidth & |
width, |
|
|
const InDetDD::SiDetectorElement * |
element, |
|
|
bool |
ganged, |
|
|
int |
errorStrategy, |
|
|
const PixelID & |
pixelID, |
|
|
bool |
split, |
|
|
double |
splitProb1, |
|
|
double |
splitProb2, |
|
|
const PixelChargeCalibCondData * |
calibData, |
|
|
const PixelCalib::PixelOfflineCalibData * |
offlineCalibData, |
|
|
const EventContext & |
ctx |
|
) |
| const |
◆ m_detStore
◆ m_evtStore
◆ m_forceErrorStrategy1B
bool InDet::ClusterMakerTool::m_forceErrorStrategy1B {false} |
|
private |
◆ m_pixelLorentzAngleTool
◆ m_pixelReadout
◆ m_sctLorentzAngleTool
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
int phi_index(const Identifier &id) const
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
float getPixelBarrelEtaError(int ibin) const
Eigen::Matrix< double, 2, 1 > Vector2D
virtual DetectorShape shape() const
Shape of element.
PixelClusterErrorData * getPixelClusterErrorData()
Trk::Surface & surface()
Element Surface.
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
#define ATH_MSG_VERBOSE(x)
virtual IdentifierHash identifyHash() const override final
identifier hash (inline)
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module) const
For a single crystal.
float getPixelEndcapPhiError(int ibin) const
const AtlasDetectorID * getIdHelper() const
Returns the id helper (inline)
virtual void setOwner(IDataHandleHolder *o)=0
float getPixelBarrelPhiError(int ibin) const
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
double phiPitch() const
Pitch (inline methods)
IdentifierHash wafer_hash(Identifier wafer_id) const
wafer hash from id
def phimod(flags, cells_name, *args, **kw)
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
Eigen::Affine3d Transform3D
int eta_index(const Identifier &id) const
float getPixelEndcapRError(int ibin) const
double R(const INavigable4Momentum *p1, const double v_eta, const double v_phi)
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
virtual HelperType helper() const
Type of helper, defaulted to 'Unimplemented'.
float etaError(const U &p)
int getBarrelBin(double eta, int etaClusterSize, int phiClusterSize) const
double charge(const T &p)
Eigen::Matrix< double, 3, 1 > Vector3D
int getEndcapBin(int etaClusterSize, int phiClusterSize) const
#define ATH_MSG_WARNING(x)
Identifier pixel_id(int barrel_ec, int layer_disk, int phi_module, int eta_module, int phi_index, int eta_index) const
For an individual pixel.
double sinStereoLocal(const Amg::Vector2D &localPos) const
Angle of strip in local frame with respect to the etaAxis.
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
constexpr double ONE_TWELFTH
float getCharge(InDetDD::PixelDiodeType type, unsigned int moduleHash, unsigned int FE, float ToT) const
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
virtual const SiDetectorDesign & design() const override final
access to the local description (inline):
constexpr int pow(int base, int exp) noexcept
const Amg::Transform3D & transform() const
Returns HepGeom::Transform3D by reference.
This class provides an interface to generate or decode an identifier for the upper levels of the dete...