ATLAS Offline Software
Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
MuonR4::EtaHoughTransformAlg Class Reference

Algorithm to handle the eta hough transform. More...

#include <EtaHoughTransformAlg.h>

Inheritance diagram for MuonR4::EtaHoughTransformAlg:
Collaboration diagram for MuonR4::EtaHoughTransformAlg:

Public Member Functions

 EtaHoughTransformAlg (const std::string &name, ISvcLocator *pSvcLocator)
 
virtual ~EtaHoughTransformAlg ()=default
 
virtual StatusCode initialize () override
 
virtual StatusCode execute (const EventContext &ctx) const override
 
virtual StatusCode sysInitialize () override
 Override sysInitialize. More...
 
virtual bool isClonable () const override
 Specify if the algorithm is clonable. More...
 
virtual unsigned int cardinality () const override
 Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant. More...
 
virtual StatusCode sysExecute (const EventContext &ctx) override
 Execute an algorithm. More...
 
virtual const DataObjIDColl & extraOutputDeps () const override
 Return the list of extra output dependencies. More...
 
virtual bool filterPassed (const EventContext &ctx) const
 
virtual void setFilterPassed (bool state, const EventContext &ctx) 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 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
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

using HoughSetupForBucket = HoughEventData::HoughSetupForBucket
 
typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

template<class ContainerType >
StatusCode retrieveContainer (const EventContext &ctx, const SG::ReadHandleKey< ContainerType > &key, const ContainerType *&contToPush) const
 Helper method to fetch data from StoreGate. More...
 
void preProcess (const EventContext &ctx, const ActsGeometryContext &gctx, const SpacePointContainer &spacePoints, HoughEventData &data) const
 pre-processing method called once per event. More...
 
void prepareHoughPlane (HoughEventData &data) const
 prepare the accumulator and the peak finder once per event More...
 
void processBucket (const EventContext &ctx, HoughEventData &data, HoughSetupForBucket &currentBucket) const
 process a bucket. More...
 
void fillFromSpacePoint (HoughEventData &data, const MuonR4::HoughHitType &SP) const
 fill the accumulator from a given space point. More...
 
bool passSeedQuality (const HoughSetupForBucket &currentBucket, const MuonR4::ActsPeakFinderForMuon::Maximum &maximum) const
 apply quality cuts on a given maximum More...
 
void extendWithPhiHits (std::vector< HoughHitType > &hitList, HoughSetupForBucket &bucket) const
 extend a maximum with all compatible (pure) phi hits. More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Static Private Member Functions

static bool isPrecisionHit (const HoughHitType &hit)
 Returns whether the hit is a precision hit or not. More...
 

Private Attributes

DoubleProperty m_targetResoTanTheta {this, "ResolutionTargetTanTheta", 0.05}
 
DoubleProperty m_targetResoIntercept {this, "ResolutionTargetIntercept", 10}
 
DoubleProperty m_minSigmasSearchTanTheta {this, "minSigmasSearchTanTheta", 2.0}
 
DoubleProperty m_minSigmasSearchIntercept {this, "minSigmasSearchIntercept", 2.0}
 
DoubleProperty m_peakThreshold {this, "peakThreshold", 2.5}
 
DoubleProperty m_minMaxDistTheta {this, "MaximumSeparationTheta", 0.}
 
DoubleProperty m_minMaxDistIntercept {this, "MaximumSeparationIntercept", 15.}
 
DoubleProperty m_peakFractionCutOff {this, "PeakFractionCutOff", 0.6}
 
UnsignedIntegerProperty m_nPrecHitCut {this, "nMinPrecHits", 3}
 
IntegerProperty m_nBinsTanTheta {this, "nBinsTanTheta", 7}
 
IntegerProperty m_nBinsIntercept {this, "nBinsIntercept", 15}
 
BooleanProperty m_downWeightMultiplePrd {this, "downWeightPrdMultiplicity", false}
 
ServiceHandle< Muon::IMuonIdHelperSvcm_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"}
 
SG::ReadHandleKey< SpacePointContainerm_spacePointKey {this, "SpacePointContainer", "MuonSpacePoints"}
 
SG::WriteHandleKey< EtaHoughMaxContainerm_maxima {this, "EtaHoughMaxContainer", "MuonHoughStationMaxima"}
 
SG::ReadHandleKey< ActsGeometryContextm_geoCtxKey {this, "AlignmentKey", "ActsAlignment", "cond handle key"}
 
ToolHandle< MuonValR4::IPatternVisualizationToolm_visionTool {this, "VisualizationTool", ""}
 Pattern visualization tool. More...
 
DataObjIDColl m_extendedExtraObjects
 Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks. More...
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Algorithm to handle the eta hough transform.

This algorithm is responsible for the initial eta hough transform from space-points created in an upstream alg. It will write HoughMaxima into the event store for downstream use.

Definition at line 31 of file EtaHoughTransformAlg.h.

Member Typedef Documentation

◆ HoughSetupForBucket

Definition at line 40 of file EtaHoughTransformAlg.h.

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ EtaHoughTransformAlg()

MuonR4::EtaHoughTransformAlg::EtaHoughTransformAlg ( const std::string &  name,
ISvcLocator *  pSvcLocator 
)

Definition at line 16 of file EtaHoughTransformAlg.cxx.

18  : AthReentrantAlgorithm(name, pSvcLocator) {}

◆ ~EtaHoughTransformAlg()

virtual MuonR4::EtaHoughTransformAlg::~EtaHoughTransformAlg ( )
virtualdefault

Member Function Documentation

◆ cardinality()

unsigned int AthReentrantAlgorithm::cardinality ( ) const
overridevirtualinherited

Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant.

Override this to return 0 for reentrant algorithms.

Override this to return 0 for reentrant algorithms.

Definition at line 55 of file AthReentrantAlgorithm.cxx.

56 {
57  return 0;
58 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation 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.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation 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.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation 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.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation 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.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ execute()

StatusCode MuonR4::EtaHoughTransformAlg::execute ( const EventContext &  ctx) const
overridevirtual

read the PRDs

pre-populate the event data - sort PRDs by station

book the hough plane

now perform the actual HT for each station

Definition at line 45 of file EtaHoughTransformAlg.cxx.

45  {
46 
48  const SpacePointContainer* spacePoints{nullptr};
49  ATH_CHECK(retrieveContainer(ctx, m_spacePointKey, spacePoints));
50 
51  // book the output container
53  ATH_CHECK(writeMaxima.record(std::make_unique<EtaHoughMaxContainer>()));
54 
55  const ActsGeometryContext* gctx{nullptr};
57 
59 
61  preProcess(ctx, *gctx, *spacePoints, data);
62 
66  for (auto& [station, stationHoughBuckets] : data.houghSetups) {
67  // reset the list of maxima
68  for (auto& bucket : stationHoughBuckets) {
69  processBucket(ctx, data, bucket);
70  }
71  for (HoughMaximum& max : data.maxima) {
72  writeMaxima->push_back(std::make_unique<HoughMaximum>(std::move(max)));
73  }
74  data.maxima.clear();
75  }
76  std::stable_sort(writeMaxima->begin(), writeMaxima->end(),
77  [](const HoughMaximum* a, const HoughMaximum* b){
78  return (*a->parentBucket()) < (*b->parentBucket());
79  });
80  return StatusCode::SUCCESS;
81 }

◆ extendWithPhiHits()

void MuonR4::EtaHoughTransformAlg::extendWithPhiHits ( std::vector< HoughHitType > &  hitList,
HoughSetupForBucket bucket 
) const
private

extend a maximum with all compatible (pure) phi hits.

Parameters
hitListlist of hits to extend
bucketthe bucket to take the phi hits from

Definition at line 396 of file EtaHoughTransformAlg.cxx.

397  {
398  for (const SpacePointBucket::value_type& hit : *bucket.bucket) {
399  if (!hit->measuresEta()) {
400  hitList.push_back(hit.get());
401  }
402  }
403 }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

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

◆ extraOutputDeps()

const DataObjIDColl & AthReentrantAlgorithm::extraOutputDeps ( ) const
overridevirtualinherited

Return the list of extra output dependencies.

This list is extended to include symlinks implied by inheritance relations.

Definition at line 79 of file AthReentrantAlgorithm.cxx.

80 {
81  // If we didn't find any symlinks to add, just return the collection
82  // from the base class. Otherwise, return the extended collection.
83  if (!m_extendedExtraObjects.empty()) {
85  }
86  return Algorithm::extraOutputDeps();
87 }

◆ fillFromSpacePoint()

void MuonR4::EtaHoughTransformAlg::fillFromSpacePoint ( HoughEventData data,
const MuonR4::HoughHitType SP 
) const
private

fill the accumulator from a given space point.

Parameters
dataevent data object
SPspace point to fill from

Definition at line 368 of file EtaHoughTransformAlg.cxx.

368  {
369 
370  using namespace std::placeholders;
371  double w = 1.0;
372  // downweight RPC measurements in the barrel relative to MDT
374  w = 0.5;
375  }
377  // if invalid time, do not count this hit towards a potential peak.
378  // The hits will still be included in a potential maximum formed by valid hits,
379  // for later recovery.
380  if (!isPrecisionHit(SP)) w = 0;
381  const auto* dc = static_cast<const xAOD::MdtDriftCircle*>(SP->primaryMeasurement());
382  // dummy index for precision layer counting within the hough plane
383  const unsigned precisionLayerIndex = (dc->readoutElement()->multilayer() * 10 + dc->tubeLayer());
384  data.houghPlane->fill<HoughHitType>(SP, data.currAxisRanges, HoughHelpers::Eta::houghParamMdtLeft,
385  std::bind(HoughHelpers::Eta::houghWidthMdt, _1, _2, m_targetResoIntercept), SP, precisionLayerIndex, w);
386  data.houghPlane->fill<HoughHitType>(SP, data.currAxisRanges, HoughHelpers::Eta::houghParamMdtRight,
387  std::bind(HoughHelpers::Eta::houghWidthMdt, _1, _2, m_targetResoIntercept), SP, precisionLayerIndex, w);
388  } else {
389  if (SP->measuresEta()) {
390  data.houghPlane->fill<HoughHitType>(SP, data.currAxisRanges, HoughHelpers::Eta::houghParamStrip,
391  std::bind(HoughHelpers::Eta::houghWidthStrip, _1, _2, m_targetResoIntercept), SP, 0, w * (
392  m_downWeightMultiplePrd ? 1.0 / SP->nEtaInstanceCounts() : 1.));
393  }
394  }
395 }

◆ filterPassed()

virtual bool AthReentrantAlgorithm::filterPassed ( const EventContext &  ctx) const
inlinevirtualinherited

Definition at line 135 of file AthReentrantAlgorithm.h.

135  {
136  return execState( ctx ).filterPassed();
137  }

◆ initialize()

StatusCode MuonR4::EtaHoughTransformAlg::initialize ( )
overridevirtual

Definition at line 20 of file EtaHoughTransformAlg.cxx.

20  {
23  ATH_CHECK(m_maxima.initialize());
24  ATH_CHECK(m_idHelperSvc.retrieve());
25  ATH_CHECK(m_visionTool.retrieve(EnableTool{!m_visionTool.empty()}));
26  return StatusCode::SUCCESS;
27 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::inputHandles ( ) const
overridevirtualinherited

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.

◆ isClonable()

bool AthReentrantAlgorithm::isClonable ( ) const
overridevirtualinherited

◆ isPrecisionHit()

bool MuonR4::EtaHoughTransformAlg::isPrecisionHit ( const HoughHitType hit)
staticprivate

Returns whether the hit is a precision hit or not.

Definition at line 125 of file EtaHoughTransformAlg.cxx.

125  {
126  switch (hit->type()){
128  const auto* dc = static_cast<const xAOD::MdtDriftCircle*>(hit->primaryMeasurement());
130  break;
131  }
134  return hit->measuresEta();
135  break;
136  default:
137  break;
138  }
139  return false;
140 }

◆ msg() [1/2]

MsgStream& AthCommonMsg< Gaudi::Algorithm >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< Gaudi::Algorithm >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< Gaudi::Algorithm >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::outputHandles ( ) const
overridevirtualinherited

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.

◆ passSeedQuality()

bool MuonR4::EtaHoughTransformAlg::passSeedQuality ( const HoughSetupForBucket currentBucket,
const MuonR4::ActsPeakFinderForMuon::Maximum &  maximum 
) const
private

apply quality cuts on a given maximum

Definition at line 154 of file EtaHoughTransformAlg.cxx.

154  {
155 
156  // helper to check if a space-point is inside a chamber
157  auto isInside = [](const SpacePointBucket::chamberLocation & loc, const Amg::Vector3D & SP){
158  return (loc.yLeft < SP.y() && SP.y() < loc.yRight && loc.zBottom < SP.z() && SP.z() < loc.zTop);
159  };
160 
161  // helper to check if our trajectory traverses a chamber
162  auto passesThrough = [](const SpacePointBucket::chamberLocation & loc, double y0, double tanTheta){
163  double yCross = (y0 + 0.5 * (loc.zBottom+loc.zTop) * tanTheta);
164  return (loc.yLeft < yCross && yCross < loc.yRight);
165  };
166 
167  // determines the local residual when traversing a chamber
168  auto proximity = []( HoughHitType dc, double y0, double tanTheta){
169  return std::min(std::abs(HoughHelpers::Eta::houghParamMdtLeft(tanTheta,dc) - y0), std::abs(HoughHelpers::Eta::houghParamMdtRight(tanTheta,dc) - y0));
170  };
171 
172  // now we propagate along the seed trajectory and collect crossed volumes
173  int expectedPrecisionChambers = 0;
174  int seenPrecisionChambers = 0;
175  bool hasTrig = false;
176  // loop over all chambers in the bucker
177  for (auto & mdtChamber : currentBucket.bucket->chamberLocations()){
178  // skip any we don't touch
179  if (!passesThrough(mdtChamber, maximum.y, maximum.x)) continue;
180  // for MDT multilayers, we increase our expected number of crossed chambers / tubes
181  if (mdtChamber.type == ActsTrk::DetectorType::Mdt){
182  ++expectedPrecisionChambers;
183  }
184  // now we check if we have a compatible measurement on our seed
185  bool hasHit = false;
186  for (auto & SP : maximum.hitIdentifiers){
187  // the hit should be inside the current volume and the local residual should be
188  // compatible with the desired resolution
189  if (isInside(mdtChamber, SP->positionInChamber()) && proximity(SP,maximum.y,maximum.x) < 2. * m_targetResoIntercept){
190  hasHit=true;
191  break;
192  }
193  }
194  // if we find an MDT hit, we increment the counter for seen chambers
195  if (mdtChamber.type == ActsTrk::DetectorType::Mdt){
196  seenPrecisionChambers += (hasHit);
197  }
198  // for trigger hits, we set a flag indicating we have at least one
199  else hasTrig |= hasHit;
200  }
201  // now count the total number of MDT tube layers we collected on our seed
202  std::set<std::pair<int,int>> seenLayers;
203  for (auto & SP : maximum.hitIdentifiers){
205  // apply a compatibility window - enforce hits are at least reasonably close
206  if (proximity(SP,maximum.y,maximum.x) < 2. * m_targetResoIntercept){
207  const xAOD::MdtDriftCircle* dc = static_cast<const xAOD::MdtDriftCircle*>(SP->primaryMeasurement());
208  seenLayers.emplace(dc->readoutElement()->multilayer(), dc->tubeLayer());
209  }
210  }
211  }
212  // compute the minimum number of requested precision layers
213  // the integer division will round down (resulting cut: 2 for single-ML, 4 for dual-ML)
214  int minLayers = seenLayers.size() / 2 + 1;
215  // require 2 precision chambers with measurements, except if we only cross one precision multilayer in total
216  int minSeenPrecisionChambers = (expectedPrecisionChambers > 1) + 1;
217  // if we have at least one trigger hit, we loosen the requirements on precision hits and chambers
218  if (hasTrig) {
219  minLayers -= 1;
220  minSeenPrecisionChambers = 1;
221  }
222 
223  return seenPrecisionChambers >= minSeenPrecisionChambers && (int)seenLayers.size() >= minLayers;
224 }

◆ prepareHoughPlane()

void MuonR4::EtaHoughTransformAlg::prepareHoughPlane ( HoughEventData data) const
private

prepare the accumulator and the peak finder once per event

Parameters
dataevent data object

Definition at line 142 of file EtaHoughTransformAlg.cxx.

142  {
143  HoughPlaneConfig cfg;
144  cfg.nBinsX = m_nBinsTanTheta;
145  cfg.nBinsY = m_nBinsIntercept;
146  ActsPeakFinderForMuonCfg peakFinderCfg;
147  peakFinderCfg.fractionCutoff = m_peakFractionCutOff;
148  peakFinderCfg.threshold = m_peakThreshold;
149  peakFinderCfg.minSpacingBetweenPeaks = {m_minMaxDistTheta, m_minMaxDistIntercept};
150  data.houghPlane = std::make_unique<HoughPlane>(cfg);
151  data.peakFinder = std::make_unique<ActsPeakFinderForMuon>(peakFinderCfg);
152 }

◆ preProcess()

void MuonR4::EtaHoughTransformAlg::preProcess ( const EventContext &  ctx,
const ActsGeometryContext gctx,
const SpacePointContainer spacePoints,
HoughEventData data 
) const
private

pre-processing method called once per event.

Populates the event data with the space points for each bucket and identifies the optimal search space in each bucket.

Parameters
ctxEventContext to parse to the visualization tool
gctxGeometry context to retrieve global positioning of the chambers
spacePointspoint list from store gate
dataevent data object

Project the hits onto the center (z=0) axis of the chamber, using our guesstimate of tan(theta)

Definition at line 82 of file EtaHoughTransformAlg.cxx.

85  {
86 
87  ATH_MSG_DEBUG("Load " << spacePoints.size() << " space point buckets");
88  for (const SpacePointBucket* bucket : spacePoints) {
89  if (m_visionTool.isEnabled()) {
90  m_visionTool->visualizeBucket(ctx, *bucket, "bucket");
91  }
92  std::vector<HoughSetupForBucket>& buckets = data.houghSetups[bucket->front()->msSector()];
93  HoughSetupForBucket& hs{buckets.emplace_back(bucket)};
94  const Amg::Transform3D globToLoc{hs.bucket->msSector()->globalToLocalTrans(gctx)};
95  Amg::Vector3D leftSide = globToLoc.translation() - (hs.bucket->coveredMin() * Amg::Vector3D::UnitY());
96  Amg::Vector3D rightSide = globToLoc.translation() - (hs.bucket->coveredMax() * Amg::Vector3D::UnitY());
97 
98  // get the average z of our hits and use it to correct our angle estimate
99  double zmin{1.e9}, zmax{-1.e9};
100  for (const std::shared_ptr<MuonR4::SpacePoint> & sp : *bucket) {
101  zmin = std::min(zmin, sp->positionInChamber().z());
102  zmax = std::max(zmax, sp->positionInChamber().z());
103  }
104  const double z = 0.5*(zmin + zmax);
105 
106  // estimate the angle, adding extra tolerance based on our target resolution
107  const double tanThetaLeft = (leftSide.y() - m_targetResoIntercept) / (leftSide.z() - z) - m_targetResoTanTheta;
108  const double tanThetaRight = (rightSide.y() + m_targetResoIntercept) / (rightSide.z() - z) + m_targetResoTanTheta;
109  hs.searchWindowTanAngle = {tanThetaLeft, tanThetaRight};
110  double ymin{1e9}, ymax{-1e9};
111 
114  for (const std::shared_ptr<MuonR4::SpacePoint> & hit : *bucket){
115  // two estimates: For the two extrema of tan(theta) resulting from the guesstimate
116  double y0l = hit->positionInChamber().y() - hit->positionInChamber().z() * tanThetaLeft;
117  double y0r = hit->positionInChamber().y() - hit->positionInChamber().z() * tanThetaRight;
118  // pick the widest envelope
121  }
122  hs.searchWindowIntercept = {ymin, ymax};
123  }
124 }

◆ processBucket()

void MuonR4::EtaHoughTransformAlg::processBucket ( const EventContext &  ctx,
HoughEventData data,
HoughSetupForBucket currentBucket 
) const
private

process a bucket.

Performs the hough transform in the given bucket and adds the maxima to the event data.

Parameters
ctxEventContext to parse to the visualization tool
dataevent data object
currentBucketbucket to process

tune the search space

Definition at line 227 of file EtaHoughTransformAlg.cxx.

229  {
231 
232  double chamberCenter = 0.5 * (bucket.searchWindowIntercept.first +
233  bucket.searchWindowIntercept.second);
234  // build a symmetric window around the (geometric) chamber center so that
235  // the bin width is equivalent to our target resolution
236  double searchStart = chamberCenter - 0.5 * data.houghPlane->nBinsY() * m_targetResoIntercept;
237  double searchEnd = chamberCenter + 0.5 * data.houghPlane->nBinsY() * m_targetResoIntercept;
238  // Protection for very wide buckets - if the search space does not cover all
239  // of the bucket, widen the bin size so that we cover everything
240  searchStart = std::min(searchStart, bucket.searchWindowIntercept.first -
242  searchEnd = std::max(searchEnd, bucket.searchWindowIntercept.second +
244  // also treat tan(theta)
245  double tanThetaMean = 0.5 * (bucket.searchWindowTanAngle.first +
246  bucket.searchWindowTanAngle.second);
247  double searchStartTanTheta = tanThetaMean - 0.5 * data.houghPlane->nBinsX() * m_targetResoTanTheta;
248  double searchEndTanTheta = tanThetaMean + 0.5 * data.houghPlane->nBinsX() * m_targetResoTanTheta;
249  searchStartTanTheta = std::min(searchStartTanTheta, bucket.searchWindowTanAngle.first -
251  searchEndTanTheta = std::max(searchEndTanTheta, bucket.searchWindowTanAngle.second +
253 
254  data.currAxisRanges = Acts::HoughTransformUtils::HoughAxisRanges{
255  searchStartTanTheta, searchEndTanTheta, searchStart, searchEnd};
256 
257  data.houghPlane->reset();
258  for (const SpacePointBucket::value_type& hit : *(bucket.bucket)) {
259  fillFromSpacePoint(data, hit.get());
260  }
261  auto maxima = data.peakFinder->findPeaks(*(data.houghPlane), data.currAxisRanges);
262  if (m_visionTool.isEnabled()) {
263  m_visionTool->visualizeAccumulator(ctx, *data.houghPlane, data.currAxisRanges, maxima,
264  "#eta Hough accumulator");
265  }
266  if (maxima.empty()) {
267  ATH_MSG_DEBUG("Station "<<bucket.bucket->msSector()->identString()
268  <<":\n Mean tanTheta was "<<tanThetaMean
269  << " and my intercept "<<chamberCenter
270  <<", with hits in the bucket in "<< bucket.bucket->coveredMin()
271  <<" - "<<bucket.bucket->coveredMax()
272  <<". The bucket found a search range of ("
273  <<bucket.searchWindowTanAngle.first<<" - "
274  <<bucket.searchWindowTanAngle.second<<") and ("
275  <<bucket.searchWindowIntercept.first<<" - "
276  <<bucket.searchWindowIntercept.second
277  <<") , and my final search range is ["
278  <<searchStartTanTheta<<" - "<<searchEndTanTheta
279  <<"] and ["<<searchStart<<" - "<<searchEnd
280  <<"] with "<<m_nBinsTanTheta<<" and "
281  <<m_nBinsIntercept<<" bins.");
282  return;
283  }
284 
285  // remember used hits - assign only to first maximum when counting
286  // precision hits
287  std::set<HoughHitType> seenHits;
288 
289  // now clean up and potentially write the maxima
290  for (const auto& max : maxima) {
291 
292  // precision hit cut, using only the measurements on the hough maximum
293  unsigned int nPrec{0};
294  auto toBins = [&data](double x, double y){
295  return std::make_pair(
296  Acts::HoughTransformUtils::binIndex(data.currAxisRanges.xMin, data.currAxisRanges.xMax, data.houghPlane->nBinsX(), x),
297  Acts::HoughTransformUtils::binIndex(data.currAxisRanges.yMin, data.currAxisRanges.yMax, data.houghPlane->nBinsY(), y)
298  );
299  };
300  auto accumulatorBins = toBins(max.x,max.y);
301  for (const HoughHitType& hit : data.houghPlane->hitIds(accumulatorBins.first, accumulatorBins.second)) {
302  auto res = seenHits.emplace(hit);
303  if (res.second){
304  nPrec += isPrecisionHit(hit);
305  }
306  }
307  if (nPrec < m_nPrecHitCut) {
308  ATH_MSG_VERBOSE("The maximum did not pass the precision hit cut");
309  continue;
310  }
311 
312  // convert the set of hit identifiers from ACTS to the vector we need later
313  std::vector<HoughHitType> hitList;
314  hitList.reserve(max.hitIdentifiers.size());
315  for (auto & hit : max.hitIdentifiers){
316  hitList.push_back(hit);
317  }
318 
319  // apply a seed quality cut.
320  if (!passSeedQuality(bucket,max)) {
321  // if seed visualisation is enabled, draw the rejected seed
322  if (m_visionTool.isEnabled()) {
323  const HoughMaximum& houghMax{max.x, max.y, (double)hitList.size(), std::move(hitList), bucket.bucket};
324  const SegmentSeed seed{houghMax};
327  for (auto & chamber : bucket.bucket->chamberLocations()){
328  primitives.push_back(MuonValR4::drawBox(chamber.yLeft, chamber.zBottom, chamber.yRight, chamber.zTop, kGray+2));
329  }
330 
331  primitives.push_back(MuonValR4::drawLabel(std::format("Missed seed - score {}, layer score {}, comprising {} measurements ",data.houghPlane->nHits(accumulatorBins.first, accumulatorBins.second),data.houghPlane->nLayers(accumulatorBins.first, accumulatorBins.second),hitList.size()),0.05,0.03,12));
332 
333  primitivesForAcc.push_back(MuonValR4::drawLabel(std::format("Missed seed - score {}, layer score {}, comprising {} measurements ",data.houghPlane->nHits(accumulatorBins.first, accumulatorBins.second),data.houghPlane->nLayers(accumulatorBins.first, accumulatorBins.second),hitList.size()),0.05,0.03,12));
334  m_visionTool->visualizeAccumulator(ctx, *data.houghPlane, data.currAxisRanges, {max},
335  "MissedAccumulator", std::move(primitivesForAcc));
336  m_visionTool->visualizeSeed(ctx, seed, "Missed seed",std::move(primitives));
337  }
338  continue;
339  }
340 
341  // this seed looks good! Let's finalise it
342  size_t nHits = hitList.size();
343  // add phi measurements - will be filtered for compatibility in separate algorithm
344  extendWithPhiHits(hitList, bucket);
345  // sort hits by layer
346  sortByLayer(hitList);
347  // create hough maximum instance and add it to the event data for later writing!
348  const HoughMaximum& houghMax{data.maxima.emplace_back(max.x, max.y, nHits, std::move(hitList), bucket.bucket)};
349 
350  // if desired, visualise the result
351  if (m_visionTool.isEnabled()) {
352  const SegmentSeed seed{houghMax};
355  for (auto & chamber : bucket.bucket->chamberLocations()){
356  primitives.push_back(MuonValR4::drawBox(chamber.yLeft, chamber.zBottom, chamber.yRight, chamber.zTop, kGray+2));
357  }
358 
359  primitives.push_back(MuonValR4::drawLabel(std::format("score {}, layer score {}, comprising {} measurements. wx = {:.2f}, wy = {:.1f} ",data.houghPlane->nHits(accumulatorBins.first, accumulatorBins.second),data.houghPlane->nLayers(accumulatorBins.first, accumulatorBins.second),hitList.size(), max.wx, max.wy),0.05,0.03,12));
360 
361  primitivesForAcc.push_back(MuonValR4::drawLabel(std::format("score {}, layer score {}, comprising {} measurements. wx = {:.2f}, wy = {:.1f} ",data.houghPlane->nHits(accumulatorBins.first, accumulatorBins.second),data.houghPlane->nLayers(accumulatorBins.first, accumulatorBins.second),hitList.size(), max.wx / m_targetResoTanTheta, max.wy / m_targetResoIntercept),0.05,0.03,12));
362 
363  m_visionTool->visualizeAccumulator(ctx, *data.houghPlane, data.currAxisRanges, {max},"#eta Hough accumulator", std::move(primitivesForAcc));
364  m_visionTool->visualizeSeed(ctx, seed, "#eta-HoughSeed", std::move(primitives));
365  }
366  }
367 }

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ retrieveContainer()

template<class ContainerType >
StatusCode MuonR4::EtaHoughTransformAlg::retrieveContainer ( const EventContext &  ctx,
const SG::ReadHandleKey< ContainerType > &  key,
const ContainerType *&  contToPush 
) const
private

Helper method to fetch data from StoreGate.

If the key is empty, a nullptr is assigned to the container ptr Failure is returned in cases, of non-empty keys and failed retrieval

Definition at line 30 of file EtaHoughTransformAlg.cxx.

32  {
33  contToPush = nullptr;
34  if (key.empty()) {
35  ATH_MSG_VERBOSE("No key has been parsed for object "
36  << typeid(ContainerType).name());
37  return StatusCode::SUCCESS;
38  }
39  SG::ReadHandle readHandle{key, ctx};
40  ATH_CHECK(readHandle.isPresent());
41  contToPush = readHandle.cptr();
42  return StatusCode::SUCCESS;
43 }

◆ setFilterPassed()

virtual void AthReentrantAlgorithm::setFilterPassed ( bool  state,
const EventContext &  ctx 
) const
inlinevirtualinherited

Definition at line 139 of file AthReentrantAlgorithm.h.

139  {
140  execState( ctx ).setFilterPassed( state );
141  }

◆ sysExecute()

StatusCode AthReentrantAlgorithm::sysExecute ( const EventContext &  ctx)
overridevirtualinherited

Execute an algorithm.

We override this in order to work around an issue with the Algorithm base class storing the event context in a member variable that can cause crashes in MT jobs.

Definition at line 67 of file AthReentrantAlgorithm.cxx.

68 {
69  return Gaudi::Algorithm::sysExecute (ctx);
70 }

◆ sysInitialize()

StatusCode AthReentrantAlgorithm::sysInitialize ( )
overridevirtualinherited

Override sysInitialize.

Override sysInitialize from the base class.

Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc

Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc

Reimplemented from AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >.

Reimplemented in InputMakerBase, and HypoBase.

Definition at line 96 of file AthReentrantAlgorithm.cxx.

96  {
98 
99  if (sc.isFailure()) {
100  return sc;
101  }
102 
103  ServiceHandle<ICondSvc> cs("CondSvc",name());
104  for (auto h : outputHandles()) {
105  if (h->isCondition() && h->mode() == Gaudi::DataHandle::Writer) {
106  // do this inside the loop so we don't create the CondSvc until needed
107  if ( cs.retrieve().isFailure() ) {
108  ATH_MSG_WARNING("no CondSvc found: won't autoreg WriteCondHandles");
109  return StatusCode::SUCCESS;
110  }
111  if (cs->regHandle(this,*h).isFailure()) {
112  sc = StatusCode::FAILURE;
113  ATH_MSG_ERROR("unable to register WriteCondHandle " << h->fullKey()
114  << " with CondSvc");
115  }
116  }
117  }
118  return sc;
119 }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_downWeightMultiplePrd

BooleanProperty MuonR4::EtaHoughTransformAlg::m_downWeightMultiplePrd {this, "downWeightPrdMultiplicity", false}
private

Definition at line 115 of file EtaHoughTransformAlg.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extendedExtraObjects

DataObjIDColl AthReentrantAlgorithm::m_extendedExtraObjects
privateinherited

Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.

Empty if no symlinks were found.

Definition at line 153 of file AthReentrantAlgorithm.h.

◆ m_geoCtxKey

SG::ReadHandleKey<ActsGeometryContext> MuonR4::EtaHoughTransformAlg::m_geoCtxKey {this, "AlignmentKey", "ActsAlignment", "cond handle key"}
private

Definition at line 123 of file EtaHoughTransformAlg.h.

◆ m_idHelperSvc

ServiceHandle<Muon::IMuonIdHelperSvc> MuonR4::EtaHoughTransformAlg::m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"}
private

Definition at line 116 of file EtaHoughTransformAlg.h.

◆ m_maxima

SG::WriteHandleKey<EtaHoughMaxContainer> MuonR4::EtaHoughTransformAlg::m_maxima {this, "EtaHoughMaxContainer", "MuonHoughStationMaxima"}
private

Definition at line 121 of file EtaHoughTransformAlg.h.

◆ m_minMaxDistIntercept

DoubleProperty MuonR4::EtaHoughTransformAlg::m_minMaxDistIntercept {this, "MaximumSeparationIntercept", 15.}
private

Definition at line 103 of file EtaHoughTransformAlg.h.

◆ m_minMaxDistTheta

DoubleProperty MuonR4::EtaHoughTransformAlg::m_minMaxDistTheta {this, "MaximumSeparationTheta", 0.}
private

Definition at line 101 of file EtaHoughTransformAlg.h.

◆ m_minSigmasSearchIntercept

DoubleProperty MuonR4::EtaHoughTransformAlg::m_minSigmasSearchIntercept {this, "minSigmasSearchIntercept", 2.0}
private

Definition at line 97 of file EtaHoughTransformAlg.h.

◆ m_minSigmasSearchTanTheta

DoubleProperty MuonR4::EtaHoughTransformAlg::m_minSigmasSearchTanTheta {this, "minSigmasSearchTanTheta", 2.0}
private

Definition at line 94 of file EtaHoughTransformAlg.h.

◆ m_nBinsIntercept

IntegerProperty MuonR4::EtaHoughTransformAlg::m_nBinsIntercept {this, "nBinsIntercept", 15}
private

Definition at line 112 of file EtaHoughTransformAlg.h.

◆ m_nBinsTanTheta

IntegerProperty MuonR4::EtaHoughTransformAlg::m_nBinsTanTheta {this, "nBinsTanTheta", 7}
private

Definition at line 110 of file EtaHoughTransformAlg.h.

◆ m_nPrecHitCut

UnsignedIntegerProperty MuonR4::EtaHoughTransformAlg::m_nPrecHitCut {this, "nMinPrecHits", 3}
private

Definition at line 107 of file EtaHoughTransformAlg.h.

◆ m_peakFractionCutOff

DoubleProperty MuonR4::EtaHoughTransformAlg::m_peakFractionCutOff {this, "PeakFractionCutOff", 0.6}
private

Definition at line 105 of file EtaHoughTransformAlg.h.

◆ m_peakThreshold

DoubleProperty MuonR4::EtaHoughTransformAlg::m_peakThreshold {this, "peakThreshold", 2.5}
private

Definition at line 99 of file EtaHoughTransformAlg.h.

◆ m_spacePointKey

SG::ReadHandleKey<SpacePointContainer> MuonR4::EtaHoughTransformAlg::m_spacePointKey {this, "SpacePointContainer", "MuonSpacePoints"}
private

Definition at line 119 of file EtaHoughTransformAlg.h.

◆ m_targetResoIntercept

DoubleProperty MuonR4::EtaHoughTransformAlg::m_targetResoIntercept {this, "ResolutionTargetIntercept", 10}
private

Definition at line 91 of file EtaHoughTransformAlg.h.

◆ m_targetResoTanTheta

DoubleProperty MuonR4::EtaHoughTransformAlg::m_targetResoTanTheta {this, "ResolutionTargetTanTheta", 0.05}
private

Definition at line 89 of file EtaHoughTransformAlg.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_visionTool

ToolHandle<MuonValR4::IPatternVisualizationTool> MuonR4::EtaHoughTransformAlg::m_visionTool {this, "VisualizationTool", ""}
private

Pattern visualization tool.

Definition at line 125 of file EtaHoughTransformAlg.h.


The documentation for this class was generated from the following files:
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
ymin
double ymin
Definition: listroot.cxx:63
MuonR4::EtaHoughTransformAlg::m_minMaxDistIntercept
DoubleProperty m_minMaxDistIntercept
Definition: EtaHoughTransformAlg.h:103
MuonR4::SpacePoint::type
xAOD::UncalibMeasType type() const
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/src/SpacePoint.cxx:131
MuonR4::EtaHoughTransformAlg::m_downWeightMultiplePrd
BooleanProperty m_downWeightMultiplePrd
Definition: EtaHoughTransformAlg.h:115
vtune_athena.format
format
Definition: vtune_athena.py:14
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
MuonR4::EtaHoughTransformAlg::m_targetResoIntercept
DoubleProperty m_targetResoIntercept
Definition: EtaHoughTransformAlg.h:91
calibdata.chamber
chamber
Definition: calibdata.py:32
PixelAthClusterMonAlgCfg.zmin
zmin
Definition: PixelAthClusterMonAlgCfg.py:169
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
max
constexpr double max()
Definition: ap_fixedTest.cxx:33
MuonR4::EtaHoughTransformAlg::m_geoCtxKey
SG::ReadHandleKey< ActsGeometryContext > m_geoCtxKey
Definition: EtaHoughTransformAlg.h:123
min
constexpr double min()
Definition: ap_fixedTest.cxx:26
AthCommonDataStore::renounce
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)
Definition: AthCommonDataStore.h:380
xAOD::UncalibMeasType::MMClusterType
@ MMClusterType
IdentifiableContainerMT::size
size_t size() const
Duplicate of fullSize for backwards compatability.
Definition: IdentifiableContainerMT.h:206
MuonValR4::drawBox
std::unique_ptr< TBox > drawBox(const Amg::Vector3D &boxCenter, const double boxWidth, const double boxHeight, const int color=kGreen+2, const int fillStyle=hollowFilling, const int view=objViewEta)
Creates a box for drawing, e.g strip measurements.
Definition: VisualizationHelpers.cxx:32
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
MuonR4::EtaHoughTransformAlg::passSeedQuality
bool passSeedQuality(const HoughSetupForBucket &currentBucket, const MuonR4::ActsPeakFinderForMuon::Maximum &maximum) const
apply quality cuts on a given maximum
Definition: EtaHoughTransformAlg.cxx:154
MuonR4::ActsPeakFinderForMuonCfg
Acts::HoughTransformUtils::PeakFinders::IslandsAroundMaxConfig ActsPeakFinderForMuonCfg
Definition: MuonHoughDefs.h:26
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
xAOD::UncalibMeasType::sTgcStripType
@ sTgcStripType
MuonR4::EtaHoughTransformAlg::HoughSetupForBucket
HoughEventData::HoughSetupForBucket HoughSetupForBucket
Definition: EtaHoughTransformAlg.h:40
x
#define x
MuonR4::HoughHitType
HoughMaximum::HitType HoughHitType
Definition: MuonHoughDefs.h:18
MuonValR4::drawLabel
std::unique_ptr< TLatex > drawLabel(const std::string &text, const double xPos, const double yPos, const unsigned int fontSize=18)
Create a TLatex label,.
Definition: VisualizationHelpers.cxx:23
Muon::MdtStatusDriftTime
@ MdtStatusDriftTime
The tube produced a vaild measurement.
Definition: MdtDriftCircleStatus.h:34
std::stable_sort
void stable_sort(std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, std::reverse_iterator< DataModel_detail::iterator< DVL > > end, Compare comp)
Specialization of stable_sort for DataVector/List.
Definition: DVL_algorithms.h:711
MuonR4::EtaHoughTransformAlg::m_minSigmasSearchTanTheta
DoubleProperty m_minSigmasSearchTanTheta
Definition: EtaHoughTransformAlg.h:94
MuonR4::EtaHoughTransformAlg::m_visionTool
ToolHandle< MuonValR4::IPatternVisualizationTool > m_visionTool
Pattern visualization tool.
Definition: EtaHoughTransformAlg.h:125
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
xAOD::MdtDriftCircle_v1::readoutElement
const MuonGMR4::MdtReadoutElement * readoutElement() const
Retrieve the associated MdtReadoutElement.
MuonR4::sortByLayer
void sortByLayer(std::vector< const SpacePoint * > &spacePoints)
Sorts the space points in a vector by z.
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/src/UtilFunctions.cxx:80
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
MuonR4::HoughEventData
HoughEventData_impl< ActsPeakFinderForMuon, ActsPeakFinderForMuonCfg > HoughEventData
Definition: HoughEventData.h:71
MuonR4::HoughHelpers::Eta::houghWidthStrip
double houghWidthStrip(double tanTheta, const MuonR4::HoughHitType &strip, double targetReso)
Uncertainty parametrisation for strip measurements.
Definition: HoughHelperFunctions.cxx:27
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
MuonR4::SpacePoint::primaryMeasurement
const xAOD::UncalibratedMeasurement * primaryMeasurement() const
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/src/SpacePoint.cxx:107
MuonGMR4::MdtReadoutElement::multilayer
unsigned int multilayer() const
Returns the multi layer of the MdtReadoutElement.
MuonR4::HoughHelpers::Eta::houghWidthMdt
double houghWidthMdt(double tanTheta, const MuonR4::HoughHitType &dc, double targetReso)
uncertainty parametrisation for drift circles
Definition: HoughHelperFunctions.cxx:21
MuonR4::EtaHoughTransformAlg::m_minMaxDistTheta
DoubleProperty m_minMaxDistTheta
Definition: EtaHoughTransformAlg.h:101
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
MuonR4::SpacePointBucket::chamberLocation
MuonGMR4::SpectrometerSector::chamberLocation chamberLocation
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/MuonSpacePoint/SpacePointContainer.h:23
AthCommonDataStore
Definition: AthCommonDataStore.h:52
Generate_dsid_ranseed.seed
seed
Definition: Generate_dsid_ranseed.py:10
AthReentrantAlgorithm::AthReentrantAlgorithm
AthReentrantAlgorithm()
Default constructor:
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
MuonR4::EtaHoughTransformAlg::m_peakThreshold
DoubleProperty m_peakThreshold
Definition: EtaHoughTransformAlg.h:99
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::outputHandles
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
xAOD::UncalibratedMeasurement_v1::type
virtual xAOD::UncalibMeasType type() const =0
Returns the type of the measurement type as a simple enumeration.
CreatePhysValWebPage.hs
hs
Definition: CreatePhysValWebPage.py:107
z
#define z
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
res
std::pair< std::vector< unsigned int >, bool > res
Definition: JetGroupProductTest.cxx:14
PixelAthClusterMonAlgCfg.zmax
zmax
Definition: PixelAthClusterMonAlgCfg.py:169
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
MuonR4::EtaHoughTransformAlg::m_nPrecHitCut
UnsignedIntegerProperty m_nPrecHitCut
Definition: EtaHoughTransformAlg.h:107
IDPVM::binIndex
unsigned int binIndex(const T &val, const std::vector< T > &partitions)
general utility function to return bin index given a value and the upper endpoints of each bin
Definition: InDetPhysValMonitoringUtilities.h:43
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
xAOD::double
double
Definition: CompositeParticle_v1.cxx:159
MuonR4::EtaHoughTransformAlg::processBucket
void processBucket(const EventContext &ctx, HoughEventData &data, HoughSetupForBucket &currentBucket) const
process a bucket.
Definition: EtaHoughTransformAlg.cxx:227
MuonR4::HoughHelpers::Eta::houghParamMdtLeft
double houghParamMdtLeft(double tanTheta, const MuonR4::HoughHitType &dc)
left-side straight line parametrisation for drift circles
Definition: HoughHelperFunctions.cxx:9
ActsGeometryContext
Include the GeoPrimitives which need to be put first.
Definition: ActsGeometryContext.h:27
AthReentrantAlgorithm::m_extendedExtraObjects
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
Definition: AthReentrantAlgorithm.h:153
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
MuonR4::EtaHoughTransformAlg::m_nBinsIntercept
IntegerProperty m_nBinsIntercept
Definition: EtaHoughTransformAlg.h:112
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
MuonR4::SegmentFit::ParamDefs::y0
@ y0
ActsTrk::DetectorType::Mdt
@ Mdt
MuonSpectrometer.
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
MuonValR4::IPatternVisualizationTool::PrimitiveVec
std::vector< PrimitivePtr > PrimitiveVec
Definition: IPatternVisualizationTool.h:31
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:77
AthReentrantAlgorithm::sysInitialize
virtual StatusCode sysInitialize() override
Override sysInitialize.
Definition: AthReentrantAlgorithm.cxx:96
WriteCaloSwCorrections.cfg
cfg
Definition: WriteCaloSwCorrections.py:23
MuonR4::EtaHoughTransformAlg::m_peakFractionCutOff
DoubleProperty m_peakFractionCutOff
Definition: EtaHoughTransformAlg.h:105
MuonR4::EtaHoughTransformAlg::m_maxima
SG::WriteHandleKey< EtaHoughMaxContainer > m_maxima
Definition: EtaHoughTransformAlg.h:121
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
MuonR4::EtaHoughTransformAlg::preProcess
void preProcess(const EventContext &ctx, const ActsGeometryContext &gctx, const SpacePointContainer &spacePoints, HoughEventData &data) const
pre-processing method called once per event.
Definition: EtaHoughTransformAlg.cxx:82
a
TList * a
Definition: liststreamerinfos.cxx:10
MuonR4::EtaHoughTransformAlg::extendWithPhiHits
void extendWithPhiHits(std::vector< HoughHitType > &hitList, HoughSetupForBucket &bucket) const
extend a maximum with all compatible (pure) phi hits.
Definition: EtaHoughTransformAlg.cxx:396
MuonR4::EtaHoughTransformAlg::m_targetResoTanTheta
DoubleProperty m_targetResoTanTheta
Definition: EtaHoughTransformAlg.h:89
y
#define y
h
MuonR4::SpacePoint::measuresEta
bool measuresEta() const
: Does the space point contain an eta measurement
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/src/SpacePoint.cxx:137
MuonR4::EtaHoughTransformAlg::m_spacePointKey
SG::ReadHandleKey< SpacePointContainer > m_spacePointKey
Definition: EtaHoughTransformAlg.h:119
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
MuonR4::EtaHoughTransformAlg::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: EtaHoughTransformAlg.h:116
MuonR4::EtaHoughTransformAlg::isPrecisionHit
static bool isPrecisionHit(const HoughHitType &hit)
Returns whether the hit is a precision hit or not.
Definition: EtaHoughTransformAlg.cxx:125
MuonR4::EtaHoughTransformAlg::m_nBinsTanTheta
IntegerProperty m_nBinsTanTheta
Definition: EtaHoughTransformAlg.h:110
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
xAOD::MdtDriftCircle_v1::status
MdtDriftCircleStatus status() const
Returns the status of the measurement.
MuonR4::EtaHoughTransformAlg::prepareHoughPlane
void prepareHoughPlane(HoughEventData &data) const
prepare the accumulator and the peak finder once per event
Definition: EtaHoughTransformAlg.cxx:142
MuonR4::EtaHoughTransformAlg::retrieveContainer
StatusCode retrieveContainer(const EventContext &ctx, const SG::ReadHandleKey< ContainerType > &key, const ContainerType *&contToPush) const
Helper method to fetch data from StoreGate.
Definition: EtaHoughTransformAlg.cxx:30
MuonR4::HoughHelpers::Eta::houghParamMdtRight
double houghParamMdtRight(double tanTheta, const MuonR4::HoughHitType &dc)
right-side straight line parametrisation for drift circles
Definition: HoughHelperFunctions.cxx:13
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
SpacePointContainer
Definition: Tracking/TrkEvent/TrkSpacePoint/TrkSpacePoint/SpacePointContainer.h:29
xAOD::MdtDriftCircle_v1::tubeLayer
uint8_t tubeLayer() const
Returns the layer number of the measurement (1-4)
LHEF::Writer
Pythia8::Writer Writer
Definition: Prophecy4fMerger.cxx:12
MuonR4::HoughHelpers::Eta::houghParamStrip
double houghParamStrip(double tanTheta, const MuonR4::HoughHitType &strip)
straight line parametrisation for strip detector measurements
Definition: HoughHelperFunctions.cxx:17
xAOD::MdtDriftCircle_v1
https://gitlab.cern.ch/atlas/athena/-/blob/master/MuonSpectrometer/MuonReconstruction/MuonRecEvent/Mu...
Definition: MdtDriftCircle_v1.h:21
python.IoTestsLib.w
def w
Definition: IoTestsLib.py:200
xAOD::UncalibMeasType::RpcStripType
@ RpcStripType
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
xAOD::UncalibMeasType::MdtDriftCircleType
@ MdtDriftCircleType
fitman.k
k
Definition: fitman.py:528
ymax
double ymax
Definition: listroot.cxx:64
ServiceHandle< ICondSvc >
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
MuonR4::EtaHoughTransformAlg::fillFromSpacePoint
void fillFromSpacePoint(HoughEventData &data, const MuonR4::HoughHitType &SP) const
fill the accumulator from a given space point.
Definition: EtaHoughTransformAlg.cxx:368
MuonR4::EtaHoughTransformAlg::m_minSigmasSearchIntercept
DoubleProperty m_minSigmasSearchIntercept
Definition: EtaHoughTransformAlg.h:97