|
ATLAS Offline Software
|
#include <EMConversionBuilder.h>
|
| EMConversionBuilder (const std::string &type, const std::string &name, const IInterface *parent) |
| Default constructor. More...
|
|
virtual | ~EMConversionBuilder ()=default |
| Destructor. More...
|
|
StatusCode | initialize () override final |
| initialize method More...
|
|
virtual StatusCode | executeRec (const EventContext &ctx, egammaRec *egRec) const override final |
| execute method More...
|
|
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 > &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 |
|
EMConversion data object builder. This is an Algorithm class. Selects conversion vertices reconstructed by the ID software after matching them to an EM calorimeter cluster. For normal two-track conversions the original photon track parameters at the conversion vertex are reconstructed. It is then extrapolated to the calorimeter and checked whether it matches the cluster. For single-track conversions, the reconstructed electron track is extrapolated to the calorimeter. A TrackToCalo extrapolation tool that can handle both neutral and charged track parameters (using a Trk::ParametersBase interface) is used throughout. The extrapolation starts at the last track measurement. Matching is done in both eta and phi. The eta matching WAS disabled for TRT-only tracks due to lack of accurate eta prediction BEFORE 12/2011.
- Author
- D. Zerwas
changes: June 16, 2010 (JM) bring some stuff from PhotonRecoveryTool here Mar, 2014 (BL) xAOD migration and new logic 2020 Athena Mt migration.
Definition at line 42 of file EMConversionBuilder.h.
◆ StoreGateSvc_t
◆ EMConversionBuilder()
EMConversionBuilder::EMConversionBuilder |
( |
const std::string & |
type, |
|
|
const std::string & |
name, |
|
|
const IInterface * |
parent |
|
) |
| |
◆ ~EMConversionBuilder()
virtual EMConversionBuilder::~EMConversionBuilder |
( |
| ) |
|
|
virtualdefault |
◆ 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]
◆ executeRec()
StatusCode EMConversionBuilder::executeRec |
( |
const EventContext & |
ctx, |
|
|
egammaRec * |
egRec |
|
) |
| const |
|
finaloverridevirtual |
◆ 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
◆ getMaxTRTTubeHitFraction()
float EMConversionBuilder::getMaxTRTTubeHitFraction |
( |
const xAOD::Vertex & |
vertex | ) |
const |
|
private |
Return the maximum fraction of TRT tube hits among the tracks.
Definition at line 217 of file EMConversionBuilder.cxx.
225 ? 1. * nTRTTube / nTRT
229 float maxTubeHitFraction = 0.;
230 for (
unsigned int i = 0;
i <
vertex.nTrackParticles(); ++
i) {
231 if (!
vertex.trackParticle(
i)) {
232 ATH_MSG_WARNING(
"NULL pointer to track particle in conversion vertex");
234 float tubeHitFraction = getTRTTubeHitFraction(
vertex.trackParticle(
i));
235 if (tubeHitFraction > maxTubeHitFraction) {
236 maxTubeHitFraction = tubeHitFraction;
240 return maxTubeHitFraction;
◆ initialize()
StatusCode EMConversionBuilder::initialize |
( |
| ) |
|
|
finaloverridevirtual |
◆ 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()
const InterfaceID & IEMConversionBuilder::interfaceID |
( |
| ) |
|
|
inlinestaticinherited |
◆ 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.
◆ passPtAndEoverP()
◆ renounce()
◆ renounceArray()
◆ 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()
◆ vertexExecute()
actual implementation method
Definition at line 123 of file EMConversionBuilder.cxx.
129 if (!egRec || !conversions) {
131 "trackExecute: NULL pointer to egammaRec or VertexContainer");
132 return StatusCode::SUCCESS;
140 for (
unsigned int iVtx = 0; iVtx < conversions->
size(); ++iVtx) {
144 if (accetaAtCalo.isAvailable(*
vertex) &&
145 accphiAtCalo.isAvailable(*
vertex)) {
146 etaAtCalo = accetaAtCalo(*
vertex);
147 phiAtCalo = accphiAtCalo(*
vertex);
151 ctx,
vertex, &etaAtCalo, &phiAtCalo)) {
159 cluster,
vertex, etaAtCalo, phiAtCalo)) {
175 return StatusCode::SUCCESS;
◆ m_conversionContainerKey
Initial value:{
this,
"ConversionContainerName",
"PhotonConversionVertices",
"Name of the input conversion container"
}
Name of conversion container.
Definition at line 78 of file EMConversionBuilder.h.
◆ m_detStore
◆ m_evtStore
◆ m_extrapolationTool
◆ m_maxEoverP_singleTrack
Gaudi::Property<float> EMConversionBuilder::m_maxEoverP_singleTrack |
|
private |
Initial value:{
this,
"maxEoverP_singleTrack",
10.,
"Maximum E/p for single track conversion vertices"
}
maximum E/p for single track conversion vertices (E is not calibrated)
Definition at line 155 of file EMConversionBuilder.h.
◆ m_maxEoverP_singleTrack_EtSf
Gaudi::Property<float> EMConversionBuilder::m_maxEoverP_singleTrack_EtSf |
|
private |
Initial value:{
this,
"maxEoverP_singleTrack_EtSf",
0.01,
"Scale maxEoverP_singleTrack by ( 1+sf*Et(cluster)/GeV )"
}
Scale maxEoverP_singleTrack by 1+sf*Et(cluster)/GeV
Definition at line 163 of file EMConversionBuilder.h.
◆ m_maxTRTTubeHitFraction
Gaudi::Property<float> EMConversionBuilder::m_maxTRTTubeHitFraction |
|
private |
Initial value:{
this,
"maxTRTTubeHitFraction",
999.,
"Maximum fraction of tube hits for vertices with TRT tracks"
}
"Maximum fraction of tube hits for vertices with TRT tracks
Definition at line 171 of file EMConversionBuilder.h.
◆ m_minPt_singleTrack
Gaudi::Property<float> EMConversionBuilder::m_minPt_singleTrack |
|
private |
Initial value:{
this,
"minPt_singleTrack",
"minimum pT for single-track conversion vertices"
}
minimum pT for single-track conversion vertices
Definition at line 113 of file EMConversionBuilder.h.
◆ m_minPt_singleTRT
Gaudi::Property<float> EMConversionBuilder::m_minPt_singleTRT |
|
private |
Initial value:{
this,
"minPt_singleTRT",
"minimum pT for TRT-only single-track conversion vertices"
}
minimum pT for TRT-only single-track conversion vertices
Definition at line 121 of file EMConversionBuilder.h.
◆ m_minSumPt_double
Gaudi::Property<float> EMConversionBuilder::m_minSumPt_double |
|
private |
Initial value:{
this,
"minSumPt_double",
"minimum sum pT for double track conversion vertices"
}
minimum sum pT for double track conversion vertices
Definition at line 138 of file EMConversionBuilder.h.
◆ m_minSumPt_doubleTRT
Gaudi::Property<float> EMConversionBuilder::m_minSumPt_doubleTRT |
|
private |
Initial value:{
this,
"minSumPt_doubleTRT",
"minimum sum pT for double TRT track conversion vertices"
}
minimum sum pT for double TRT track conversion vertices
Definition at line 146 of file EMConversionBuilder.h.
◆ m_minTRTHits
Gaudi::Property<int> EMConversionBuilder::m_minTRTHits |
|
private |
Initial value:{
this,
"minTRTHits",
0,
"minimum number of TRT hits for TRT-only tracks (both single and double "
"track conversion vertices)"
}
minimum number of TRT hits for TRT-only tracks (both single and double track conversion vertices)
Definition at line 104 of file EMConversionBuilder.h.
◆ m_minTRTonlyTrackPt
Gaudi::Property<float> EMConversionBuilder::m_minTRTonlyTrackPt |
|
private |
Initial value:{
this,
"minTRTonlyTrackPt",
"minimum pT for each track in TRT-only double-track conversion vertices"
}
minimum pT for each track in TRT-only double-track conversion vertices
Definition at line 130 of file EMConversionBuilder.h.
◆ m_rejectAllTRT
Gaudi::Property<bool> EMConversionBuilder::m_rejectAllTRT |
|
private |
Initial value:{
this,
"RejectAllTRTConversions",
false,
"Ignore all conversion vertices containing exclusively TRT-only tracks"
}
Ignore all conversion vertices that contain exclusively TRT-only tracks.
Definition at line 95 of file EMConversionBuilder.h.
◆ m_varHandleArraysDeclared
◆ m_vhka
The documentation for this class was generated from the following files:
void pushFrontVertex(const ElementLink< xAOD::VertexContainer > &vertexElementLink)
Push front another vertex.
size_t getNumberOfVertices() const
Return the number xAOD::Vertex/vertices that match the photon candidate.
Helper class to provide type-safe access to aux data.
Gaudi::Property< float > m_maxTRTTubeHitFraction
"Maximum fraction of tube hits for vertices with TRT tracks
Gaudi::Property< float > m_minSumPt_double
minimum sum pT for double track conversion vertices
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Gaudi::Property< float > m_minSumPt_doubleTRT
minimum sum pT for double TRT track conversion vertices
Gaudi::Property< float > m_maxEoverP_singleTrack
maximum E/p for single track conversion vertices (E is not calibrated)
const xAOD::CaloCluster * caloCluster(size_t index=0) const
Pointer to the xAOD::CaloCluster/s that define the electron candidate.
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
float getMaxTRTTubeHitFraction(const xAOD::Vertex &vertex) const
Return the maximum fraction of TRT tube hits among the tracks.
ToolHandle< IEMExtrapolationTools > m_extrapolationTool
EMExtrapolationTools.
@ numberOfTRTHits
number of TRT hits [unit8_t].
float phiBE(const unsigned layer) const
Get the phi in one layer of the EM Calo.
@ numberOfTRTTubeHits
number of TRT tube hits [unit8_t].
SG::ReadHandleKey< xAOD::VertexContainer > m_conversionContainerKey
Name of conversion container.
virtual void setOwner(IDataHandleHolder *o)=0
bool passPtAndEoverP(const EventContext &ctx, const xAOD::Vertex &, const xAOD::CaloCluster &) const
Return true if vertex and cluster pass Pt and E/p cuts.
float etaBE(const unsigned layer) const
Get the eta in one layer of the EM Calo.
Description of a calorimeter cluster.
double deltaPhi(double phiA, double phiB)
delta Phi in range [-pi,pi[
void setDeltaPhiVtx(float value)
set deltaPhiVtx
StatusCode vertexExecute(const EventContext &ctx, egammaRec *egRec, const xAOD::VertexContainer *conversions) const
actual implementation method
void pushBackVertex(const ElementLink< xAOD::VertexContainer > &vertexElementLink)
Push back another vertex.
Gaudi::Property< float > m_minPt_singleTrack
minimum pT for single-track conversion vertices
void setVertices(const std::vector< ElementLink< xAOD::VertexContainer >> &links)
set Pointer to the xAOD::vertex/vertices that match the photon candidate
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
@ singleTRT
one track only, no Si hits (TRT only)
void setDeltaEtaVtx(float value)
set deltaEtaVtx
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
ElementLink implementation for ROOT usage.
@ singleSi
one track only, with Si hits
Eigen::Matrix< double, 3, 1 > Vector3D
Class describing a Vertex.
Gaudi::Property< float > m_minPt_singleTRT
minimum pT for TRT-only single-track conversion vertices
const xAOD::Vertex * vertex(size_t index=0) const
Pointer to the xAOD::Vertex/es that match the photon candidate.
#define ATH_MSG_WARNING(x)
Gaudi::Property< float > m_maxEoverP_singleTrack_EtSf
Scale maxEoverP_singleTrack by 1+sf*Et(cluster)/GeV
xAOD::EgammaParameters::ConversionType conversionType(const xAOD::Photon *ph)
return the photon conversion type (see EgammaEnums)
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
@ doubleTRT
two tracks, none with Si hits (TRT only)
Class describing a TrackParticle.
const T * at(size_type n) const
Access an element, as an rvalue.
Gaudi::Property< bool > m_rejectAllTRT
Ignore all conversion vertices that contain exclusively TRT-only tracks.
size_type size() const noexcept
Returns the number of elements in the collection.
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
virtual double e() const
The total energy of the particle.