![]() |
ATLAS Offline Software
|
#include <TrackAnalysisStore.h>
Public Types | |
| using | beam_key_t = SG::ReadDecorHandleKeyArray<xAOD::EventInfo> |
| using | keys_t = SG::ReadDecorHandleKeyArray<xAOD::EventInfo> |
Public Member Functions | |
| TrackAnalysisStore (const std::string &anaTag, const EventContext &context) | |
| Constructor. | |
| TrackAnalysisStore (const std::string &anaTag, const ToolHandle< Trig::TrigDecisionTool > *tdt, const EventContext &context) | |
| ~TrackAnalysisStore ()=default | |
| Destructor. | |
| TrackAnalysisStore & | operator= (const TrackAnalysisStore &)=delete |
| = operator | |
| StatusCode | initialize () |
| initialize this should not actually be needed - we should be creating a new instance whenever this is required, so all the "initialisation" could be moved to the constructor | |
| const std::string & | anaTag () |
| — Setter methods — | |
| const std::vector< ParentView > & | parents () const |
| const TIDA::Associator< const TrackView > * | matcher () const |
| test and reference tracks ... | |
| void | set_matcher (const TIDA::Associator< const TrackView > *m) |
| const std::vector< const TrackView * > & | reference_tracks () const |
| const std::vector< const TrackView * > & | test_tracks () const |
| std::vector< const TrackView * > & | reference_tracks () |
| std::vector< const TrackView * > & | test_tracks () |
| void | reference_tracks (const std::vector< const TrackView * > &v) |
| these are a bit dodgy - ie we pass in a vector<const TrackView*> so we want to construct a reference veiw_store_t ? | |
| void | test_tracks (const std::vector< const TrackView * > &v) |
| const std::vector< const VertexView * > & | refvertices () const |
| vertex accessors | |
| const std::vector< const VertexView * > & | testvertices () const |
| std::vector< const VertexView * > & | refvertices () |
| std::vector< const VertexView * > & | testvertices () |
| void | set_vertex_matcher (const TIDA::Associator< const VertexView > *m) |
| const TIDA::Associator< const VertexView > * | vertex_matcher () const |
| const xAOD::EventInfo * | eventInfo () const |
| get event info | |
| const xAOD::TruthEventContainer * | truthEventContainer () const |
| const xAOD::TruthPileupEventContainer * | truthPileupEventContainer () const |
| int | roiIndex () const |
| odds n ends ... | |
| void | roiIndex (int i) |
| template<typename T> | |
| StatusCode | fillInfo (const T *&t, const std::string &key) |
| filling methods to fetch collections ... | |
| template<typename Collection> | |
| std::pair< typename Collection::const_iterator, typename Collection::const_iterator > | getPair (const ElementLink< TrigRoiDescriptorCollection > &roi_link, const std::string &key) |
| StatusCode | fillEventInfo (const std::string &key) |
| void | fillViewRef (const std::string &key) |
| track fillers ... | |
| void | fillViewTest (const std::string &key) |
| void | fillViewTest (const std::string &key, const ElementLink< TrigRoiDescriptorCollection > &roi_link) |
| Roi filler ... | |
| void | fillVertexViewRef (const std::string &key) |
| vertex fillers ... | |
| void | fillVertexViewTest (const std::string &key) |
| void | fillVertexViewTest (const std::string &key, const ElementLink< TrigRoiDescriptorCollection > &roi_link) |
| void | fillEventInfo (const xAOD::EventInfo *e) |
| bool | hasTagNProbe () const |
| void | addTagNProbe (const TagNProbe *t) |
| const TagNProbe * | tagNProbe () const |
| void | setBeamKeys (const beam_key_t *k) |
| void | decoratePerigee () |
| bool | msgLvl (const MSG::Level lvl) const |
| Test the output level. | |
| MsgStream & | msg () const |
| The standard message stream. | |
| MsgStream & | msg (const MSG::Level lvl) const |
| The standard message stream. | |
| void | setLevel (MSG::Level lvl) |
| Change the current logging level. | |
Protected Types | |
| using | view_store_t = std::vector<std::unique_ptr<TrackView>> |
| polymoprphic master store types | |
| using | vtx_store_t = std::vector<std::unique_ptr<VertexView>> |
Protected Member Functions | |
| void | fillView (const std::string &key, view_store_t &trackView) |
| track fillers ... | |
| void | fillView (const std::string &key, const ElementLink< TrigRoiDescriptorCollection > &roi_link, view_store_t &trackView) |
| must be a better way that to have a duplicated function, but only one I can think of is to pass in the TrackView, and both TrackParticle and TruthParticle contaiuners | |
| void | fillView (const std::string &key, vtx_store_t &vertexView) |
| track vertices ... | |
| void | fillView (const std::string &key, const ElementLink< TrigRoiDescriptorCollection > &roi_link, vtx_store_t &vertexView) |
| this and the roi based TrackView fillView should really be done with a single template | |
| template<typename T, typename U, typename V = U> | |
| bool | fillView_internal (const std::string &key, std::vector< std::unique_ptr< U > > &outView) |
| templates for athena type track and vertex retrieval ... | |
| template<typename T> | |
| bool | fillView_internal (const std::string &key, std::vector< ParentView > &parentView) |
| the specialisation for the ParentView, because we want to retrieve the parent, and then get the child tracks to add to the tracks for the analysis, and then add the lookup back to the parent on those tracks | |
| template<typename T> | |
| StatusCode | fill (T const *&container, const std::string &key) |
| have the eventInfo already ?? then just pass in the pointer | |
| template<typename T> | |
| StatusCode | fillRoi (std::pair< typename T::const_iterator, typename T::const_iterator > &itrpair, const std::string &key, const ElementLink< TrigRoiDescriptorCollection > &roi_link) |
| more rational generic Roi fill method | |
| const EventContext & | eventContext () const |
| void | trackptrs (const view_store_t &v, std::vector< const TrackView * > &vp) |
| do this with a single template for treacks and vertices | |
| void | trackptrs (const std::vector< ParentView > &v, std::vector< const TrackView * > &vp) |
| void | vertexptrs (const vtx_store_t &v, std::vector< const VertexView * > &vp) |
| template<typename T> | |
| bool | isGoodOffline (const T &, const std::string &, const std::string &="")=delete |
| to be over ridden by selection for actual EDM classes | |
Protected Attributes | |
| view_store_t | m_reftracks |
| tracks | |
| view_store_t | m_testtracks |
| std::vector< ParentView > | m_parents |
| std::vector< const TrackView * > | m_reftrackptr |
| std::vector< const TrackView * > | m_testtrackptr |
| const EventContext & | m_context |
| const TIDA::Associator< const TrackView > * | m_matcher = 0 |
| store the track matches in an actual simple way | |
| vtx_store_t | m_refvertices_raw |
| vtx_store_t | m_testvertices_raw |
| std::vector< const VertexView * > | m_refvertices |
| std::vector< const VertexView * > | m_testvertices |
| const TIDA::Associator< const VertexView > * | m_vertex_matcher = 0 |
| store the vertex matches in an actual simple way NB: a vertex match can be quite complex: two vertices can have similar z positions, but different tracks | |
| const ToolHandle< Trig::TrigDecisionTool > * | m_tdt |
| Actually, actually, we don;t even need this AT ALL, it serves no purpose since we can control everything from the main execute() method as and when required, so this actually serves no real purpose any longer. | |
| int | m_roiIndex |
| const xAOD::EventInfo * | m_eventInfo = nullptr |
| — Collections class variables — EventInfo, TruthEvent, and TruthPUEvent | |
| const xAOD::TruthEventContainer * | m_truthEventContainer = nullptr |
| const xAOD::TruthPileupEventContainer * | m_truthPUEventContainer = nullptr |
| const TagNProbe * | m_tnp = 0 |
| TrackAnalysis properties why do ALL these classes have independent m_anaTag variables ? | |
| std::string | m_anaTag |
| const beam_key_t * | m_beamkeys = 0 |
| enable / diable local truth decoration handling | |
Private Member Functions | |
| void | initMessaging () const |
| Initialize our message level and MessageSvc. | |
Private Attributes | |
| std::string | m_nm |
| Message source name. | |
| boost::thread_specific_ptr< MsgStream > | m_msg_tls |
| MsgStream instance (a std::cout like with print-out levels). | |
| std::atomic< IMessageSvc * > | m_imsg { nullptr } |
| MessageSvc pointer. | |
| std::atomic< MSG::Level > | m_lvl { MSG::NIL } |
| Current logging level. | |
| std::atomic_flag m_initialized | ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT |
| Messaging initialized (initMessaging). | |
Definition at line 78 of file TrackAnalysisStore.h.
Definition at line 82 of file TrackAnalysisStore.h.
Definition at line 215 of file TrackAnalysisStore.h.
|
protected |
polymoprphic master store types
Definition at line 225 of file TrackAnalysisStore.h.
|
protected |
Definition at line 227 of file TrackAnalysisStore.h.
| IDTPM2::TrackAnalysisStore::TrackAnalysisStore | ( | const std::string & | anaTag, |
| const EventContext & | context ) |
Constructor.
Definition at line 39 of file TrackAnalysisStore.cxx.
| IDTPM2::TrackAnalysisStore::TrackAnalysisStore | ( | const std::string & | anaTag, |
| const ToolHandle< Trig::TrigDecisionTool > * | tdt, | ||
| const EventContext & | context ) |
Definition at line 47 of file TrackAnalysisStore.cxx.
|
default |
Destructor.
Definition at line 211 of file TrackAnalysisStore.h.
|
inline |
| void IDTPM2::TrackAnalysisStore::decoratePerigee | ( | ) |
can extrapolate to the beamline perigee, if we don't know where the beamline is ...
only currently bother with this for actual, Truth/Particles ...
add perigee parameters ... NB: could make this add perigee parameters only when actually requested ...
should always have a production vertex ...
all of this would probably be much better, and certainiy more compact using some vector types ...
do we really want to bother for neutrals ???
siimple ultra-fast limear extrapolations ...
linear ...
do we need this ?
Definition at line 222 of file TrackAnalysisStore.cxx.
|
inlineprotected |
Definition at line 274 of file TrackAnalysisStore.h.
|
inline |
get event info
Definition at line 148 of file TrackAnalysisStore.h.
|
protected |
have the eventInfo already ?? then just pass in the pointer
more rational generic fill method
more rational generic fill methods
Definition at line 405 of file TrackAnalysisStore.h.
|
inline |
Definition at line 171 of file TrackAnalysisStore.h.
|
inline |
Definition at line 207 of file TrackAnalysisStore.h.
| StatusCode IDTPM2::TrackAnalysisStore::fillInfo | ( | const T *& | t, |
| const std::string & | key ) |
filling methods to fetch collections ...
Definition at line 437 of file TrackAnalysisStore.h.
|
protected |
more rational generic Roi fill method
Definition at line 418 of file TrackAnalysisStore.h.
|
inline |
vertex fillers ...
Definition at line 199 of file TrackAnalysisStore.h.
|
inline |
Definition at line 201 of file TrackAnalysisStore.h.
|
inline |
Definition at line 203 of file TrackAnalysisStore.h.
|
protected |
must be a better way that to have a duplicated function, but only one I can think of is to pass in the TrackView, and both TrackParticle and TruthParticle contaiuners
don't need to bother with TruthParticles as they are not reconstructed in an Roi
Definition at line 91 of file TrackAnalysisStore.cxx.
|
protected |
this and the roi based TrackView fillView should really be done with a single template
this and the roi based TrackView fillView should really be done with a single template eventually, likelyt create Parent and Child VertexViews as from the TrackView, then we can have the vertices own their own tracks and we would be unstoppable I tell you !
!
don't need to bother with TruthVertices as they are not reconstructed in an Roi
Definition at line 119 of file TrackAnalysisStore.cxx.
|
protected |
track fillers ...
track stuff ...
this is a bit naughty - using the m_parents directly rather than passing it in - prevents being able to use this mechanism for the test corrections as well, so perhaps it could be changed, should change this to always pass in both a TrackView and a ParentView vectors
Definition at line 77 of file TrackAnalysisStore.cxx.
|
protected |
track vertices ...
vertex stuff ... now we have the child-parent relationship sorted out, these vertices should really become ParentViews containing the pointers to all their tracks
Definition at line 109 of file TrackAnalysisStore.cxx.
|
protected |
the specialisation for the ParentView, because we want to retrieve the parent, and then get the child tracks to add to the tracks for the analysis, and then add the lookup back to the parent on those tracks
Definition at line 388 of file TrackAnalysisStore.h.
|
protected |
templates for athena type track and vertex retrieval ...
Definition at line 371 of file TrackAnalysisStore.h.
|
inline |
track fillers ...
Definition at line 182 of file TrackAnalysisStore.h.
|
inline |
Definition at line 188 of file TrackAnalysisStore.h.
|
inline |
Roi filler ...
Definition at line 192 of file TrackAnalysisStore.h.
| std::pair< typename Collection::const_iterator, typename Collection::const_iterator > IDTPM2::TrackAnalysisStore::getPair | ( | const ElementLink< TrigRoiDescriptorCollection > & | roi_link, |
| const std::string & | key ) |
access by a pair of begin and end iterators
Definition at line 450 of file TrackAnalysisStore.h.
|
inline |
Definition at line 209 of file TrackAnalysisStore.h.
| StatusCode IDTPM2::TrackAnalysisStore::initialize | ( | ) |
initialize this should not actually be needed - we should be creating a new instance whenever this is required, so all the "initialisation" could be moved to the constructor
this was a tool, instantiated, AS NEW for EVERY event, therefor having an initialize() method of this nature is completely pointless - so now everything is done in the constructor and the initialise is actually redundent. Also the DefinitioSvc is not needed, as the required information can simply be passed in from the top level tool.
Definition at line 66 of file TrackAnalysisStore.cxx.
|
privateinherited |
Initialize our message level and MessageSvc.
This method should only be called once.
Definition at line 39 of file AthMessaging.cxx.
|
protecteddelete |
to be over ridden by selection for actual EDM classes
|
inline |
test and reference tracks ...
these are all the accessors you actually should ever need ... local matcher ...
Definition at line 116 of file TrackAnalysisStore.h.
|
inlineinherited |
The standard message stream.
Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.
Definition at line 167 of file AthMessaging.h.
|
inlineinherited |
The standard message stream.
Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.
Definition at line 182 of file AthMessaging.h.
|
inlineinherited |
Test the output level.
| lvl | The message level to test against |
| true | Messages at level "lvl" will be printed |
Definition at line 151 of file AthMessaging.h.
|
delete |
= operator
|
inline |
Definition at line 108 of file TrackAnalysisStore.h.
Definition at line 123 of file TrackAnalysisStore.h.
|
inline |
Definition at line 120 of file TrackAnalysisStore.h.
|
inline |
these are a bit dodgy - ie we pass in a vector<const TrackView*> so we want to construct a reference veiw_store_t ?
? this would mean making copies of the original TrackView objects, so now we would have two, seperate sets of pointers to copies of the same objects so we don't want this, and so we clear the raw view
Definition at line 131 of file TrackAnalysisStore.h.
|
inline |
Definition at line 139 of file TrackAnalysisStore.h.
|
inline |
|
inline |
|
inline |
Definition at line 157 of file TrackAnalysisStore.h.
|
inline |
Definition at line 118 of file TrackAnalysisStore.h.
|
inline |
Definition at line 142 of file TrackAnalysisStore.h.
|
inline |
Definition at line 217 of file TrackAnalysisStore.h.
|
inherited |
Change the current logging level.
Use this rather than msg().setLevel() for proper operation with MT.
Definition at line 28 of file AthMessaging.cxx.
Definition at line 213 of file TrackAnalysisStore.h.
Definition at line 124 of file TrackAnalysisStore.h.
Definition at line 121 of file TrackAnalysisStore.h.
Definition at line 132 of file TrackAnalysisStore.h.
|
inline |
Definition at line 140 of file TrackAnalysisStore.h.
|
inline |
Definition at line 137 of file TrackAnalysisStore.h.
|
inlineprotected |
Definition at line 279 of file TrackAnalysisStore.h.
|
inlineprotected |
do this with a single template for treacks and vertices
Definition at line 277 of file TrackAnalysisStore.h.
|
inline |
Definition at line 149 of file TrackAnalysisStore.h.
|
inline |
Definition at line 150 of file TrackAnalysisStore.h.
|
inline |
Definition at line 144 of file TrackAnalysisStore.h.
|
inlineprotected |
Definition at line 284 of file TrackAnalysisStore.h.
|
mutableprivateinherited |
Messaging initialized (initMessaging).
Definition at line 141 of file AthMessaging.h.
|
protected |
Definition at line 358 of file TrackAnalysisStore.h.
|
protected |
enable / diable local truth decoration handling
Definition at line 363 of file TrackAnalysisStore.h.
|
protected |
Definition at line 303 of file TrackAnalysisStore.h.
|
protected |
— Collections class variables — EventInfo, TruthEvent, and TruthPUEvent
Definition at line 345 of file TrackAnalysisStore.h.
|
mutableprivateinherited |
|
mutableprivateinherited |
|
protected |
store the track matches in an actual simple way
Definition at line 307 of file TrackAnalysisStore.h.
|
mutableprivateinherited |
MsgStream instance (a std::cout like with print-out levels).
Definition at line 132 of file AthMessaging.h.
|
privateinherited |
Message source name.
Definition at line 129 of file AthMessaging.h.
|
protected |
Definition at line 298 of file TrackAnalysisStore.h.
Definition at line 300 of file TrackAnalysisStore.h.
|
protected |
tracks
Definition at line 295 of file TrackAnalysisStore.h.
|
protected |
Definition at line 314 of file TrackAnalysisStore.h.
|
protected |
Definition at line 311 of file TrackAnalysisStore.h.
|
protected |
Definition at line 341 of file TrackAnalysisStore.h.
|
protected |
Actually, actually, we don;t even need this AT ALL, it serves no purpose since we can control everything from the main execute() method as and when required, so this actually serves no real purpose any longer.
actually, we don't want to use a service handle for this, we extract it at the tool level, and pass it in when this tool is constructed for each event We stick with the Svc name however for the time being to avoid having to change the code that much SmartIF< ITrackAnalysisDefinitionSvc > m_trkAnaDefSvc; const ITrackAnalysisDefinition* m_trkAnaDefSvc; TrigDecisionTool - we don;t want to retrieve this tool ourselves, we can have it passed in by the parent tool
Definition at line 339 of file TrackAnalysisStore.h.
Definition at line 301 of file TrackAnalysisStore.h.
|
protected |
Definition at line 296 of file TrackAnalysisStore.h.
|
protected |
Definition at line 315 of file TrackAnalysisStore.h.
|
protected |
Definition at line 312 of file TrackAnalysisStore.h.
TrackAnalysis properties why do ALL these classes have independent m_anaTag variables ?
this is very dangerous, as none of them applear to ever be checked - there should be one analTag for an analysis, and all the tools in the analysis use the same thing
Definition at line 356 of file TrackAnalysisStore.h.
|
protected |
Definition at line 346 of file TrackAnalysisStore.h.
|
protected |
Definition at line 347 of file TrackAnalysisStore.h.
|
protected |
store the vertex matches in an actual simple way NB: a vertex match can be quite complex: two vertices can have similar z positions, but different tracks
Definition at line 321 of file TrackAnalysisStore.h.