ATLAS Offline Software
Classes | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Private Types | Private Member Functions | Private Attributes | List of all members
CP::MuonCalibIntSagittaTool Class Referenceabstract

#include <MuonCalibIntSagittaTool.h>

Inheritance diagram for CP::MuonCalibIntSagittaTool:
Collaboration diagram for CP::MuonCalibIntSagittaTool:

Classes

struct  ParameterSetSagitta
 

Public Member Functions

 MuonCalibIntSagittaTool (const std::string &name)
 
virtual ~MuonCalibIntSagittaTool ()=default
 
virtual StatusCode initialize () override
 Dummy implementation of the initialisation function. More...
 
virtual CorrectionCode applyCorrection (MCP::MuonObj &mu) const =0
 Declare the interface that the class provides. More...
 
virtual void print () const =0
 Print the state of the tool. More...
 
virtual void print () const
 Print the state of the tool. 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
 

Protected Types

typedef std::map< MCP::SagittaCorrection, std::shared_ptr< MCP::CalibContainer > > SagittaCorrConstMap
 

Protected Member Functions

StatusCode calcSystematicVariation (const SystematicSet &systConfig, ParameterSetSagitta &param) const
 
void applySagittaCorrection (double &pt, const std::vector< double > &correction, const int &charge, const bool &isData) const
 
std::vector< double > getCorrections (const MCP::TrackCalibObj &mu) const
 
double statCombCorrection (const MCP::MuonObj &mu, double corrIDpT, double corrMEpT, double CBpT) const
 
CorrectionCode applyStatCombination (AmgVector(5) parsID, const AmgSymMatrix(5)&covID, AmgVector(5) parsMS, const AmgSymMatrix(5)&covMS, int charge, AmgVector(5) &parsCB, AmgSymMatrix(5) &covCB, double &chi2) const
 
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...
 

Protected Attributes

SG::ReadHandleKey< xAOD::EventInfom_eventInfo {this, "EventInfoContName", "EventInfo", "event info key"}
 
Gaudi::Property< std::string > m_release {this, "release", "Recs2024_05_06_Run2Run3", "Release"}
 
Gaudi::Property< bool > m_doEtaSagittaSys {this, "doEtaSagittaSys", false, "Do Eta dependant systematic system"}
 
Gaudi::Property< bool > m_applyCorrectionOnData {this, "applyCorrectionOnData", true, "If to apply sagitta corrections on data, or take the full effect as systematic"}
 
Gaudi::Property< bool > m_doDirectCBCalib {this, "doDirectCBCalib", true, "Apply sagitta corrections on CB tracks, otherwise, on ID+MS"}
 
Gaudi::Property< bool > m_useFixedRho {this, "useFixedRho", true, "Force Fixed Rho"}
 
Gaudi::Property< float > m_fixedRhoValue {this, "fixedRhoValue", 1, "Value for rho, if it is forced"}
 
Gaudi::Property< std::string > m_sysScheme {this, "systematicScheme", "Corr_Scale", "Systematic scheme to be configured"}
 
Gaudi::Property< float > m_extraRebiasSys {this, "extraRebias", 0.00002, "Additional systematic applied for the residual bias observed"}
 
SystematicsCache< ParameterSetSagittam_Parameters {this}
 
const ParameterSetSagittam_currentParameters {nullptr}
 
std::map< MCP::DataYear, SagittaCorrConstMapm_sagittaCorrConst_ID
 
std::map< MCP::DataYear, SagittaCorrConstMapm_sagittaCorrConst_ME
 
std::map< MCP::DataYear, SagittaCorrConstMapm_sagittaCorrConst_CB
 
std::map< MCP::DataYear, SagittaCorrConstMapm_sagittaCorrConst_mcID
 
std::map< MCP::DataYear, SagittaCorrConstMapm_sagittaCorrConst_mcME
 
std::map< MCP::DataYear, SagittaCorrConstMapm_sagittaCorrConst_mcCB
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

virtual ASG_TOOL_CLASS3(MuonCalibIntSagittaTool, CP::IMuonCalibIntTool, CP::ISystematicsTool, CP::IReentrantSystematicsTool) public bool isAffectedBySystematic (const SystematicVariation &systematic) const override
 Declare the interface that this class provides. More...
 
virtual SystematicSet affectingSystematics () const override
 the list of all systematics this tool can be affected by More...
 
virtual SystematicSet recommendedSystematics () const override
 the list of all systematics this tool recommends to use More...
 
virtual StatusCode applySystematicVariation (const SystematicSet &systConfig) override
 effects: configure this tool for the given list of systematic variations. 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...
 

Private Attributes

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

Definition at line 27 of file MuonCalibIntSagittaTool.h.

Member Typedef Documentation

◆ SagittaCorrConstMap

Definition at line 95 of file MuonCalibIntSagittaTool.h.

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ MuonCalibIntSagittaTool()

CP::MuonCalibIntSagittaTool::MuonCalibIntSagittaTool ( const std::string &  name)

Definition at line 20 of file MuonCalibIntSagittaTool.cxx.

21  { }

◆ ~MuonCalibIntSagittaTool()

virtual CP::MuonCalibIntSagittaTool::~MuonCalibIntSagittaTool ( )
virtualdefault

Member Function Documentation

◆ affectingSystematics()

SystematicSet CP::MuonCalibIntSagittaTool::affectingSystematics ( ) const
overrideprivatevirtual

the list of all systematics this tool can be affected by

Sagitta Systematis

Implements CP::IReentrantSystematicsTool.

Definition at line 443 of file MuonCalibIntSagittaTool.cxx.

444  {
445  SystematicSet result;
449  if (!m_useFixedRho || m_sysScheme == "AllSys") {
450  result.insert(SystematicVariation("MUON_SAGITTA_RHO", 1));
451  result.insert(SystematicVariation("MUON_SAGITTA_RHO", -1));
452  }
453 
454  if (m_doEtaSagittaSys) {
455  // Sagitta correction residual bias
456  result.insert(SystematicVariation("MUON_SAGITTA_RESBIAS_NEGETA", 1));
457  result.insert(SystematicVariation("MUON_SAGITTA_RESBIAS_NEGETA", -1));
458 
459  result.insert(SystematicVariation("MUON_SAGITTA_RESBIAS_POSETA", 1));
460  result.insert(SystematicVariation("MUON_SAGITTA_RESBIAS_POSETA", -1));
461 
462  }
463  else {
464  // Sagitta correction residual bias
465  result.insert(SystematicVariation("MUON_SAGITTA_RESBIAS", 1));
466  result.insert(SystematicVariation("MUON_SAGITTA_RESBIAS", -1));
467  }
468 
469  result.insert(SystematicVariation("MUON_SAGITTA_DATASTAT", 1));
470  result.insert(SystematicVariation("MUON_SAGITTA_DATASTAT", -1));
471 
472  result.insert(SystematicVariation("MUON_SAGITTA_GLOBAL", 1));
473  result.insert(SystematicVariation("MUON_SAGITTA_GLOBAL", -1));
474 
475  result.insert(SystematicVariation("MUON_SAGITTA_PTEXTRA", 1));
476  result.insert(SystematicVariation("MUON_SAGITTA_PTEXTRA", -1));
477 
478  return result;
479  }

◆ applyCorrection()

virtual CorrectionCode CP::IMuonCalibIntTool::applyCorrection ( MCP::MuonObj mu) const
pure virtualinherited

Declare the interface that the class provides.

Apply the correction on a modifyable object

◆ applySagittaCorrection()

void CP::MuonCalibIntSagittaTool::applySagittaCorrection ( double &  pt,
const std::vector< double > &  correction,
const int &  charge,
const bool &  isData 
) const
protected

Definition at line 134 of file MuonCalibIntSagittaTool.cxx.

135  {
136  for(const auto& corr: correction)
137  {
138  double originalPt = pt;
139  if(isData) pt = pt / (1 + charge * corr * pt);
140  else pt = pt / (1 - charge * corr * pt);
141  ATH_MSG_DEBUG("CorrectForCharge - in pT: " << originalPt << " corrPt: " << pt << " applied saggita: " << corr);
142 
143  }
144  }

◆ applyStatCombination()

CorrectionCode CP::MuonCalibIntSagittaTool::applyStatCombination ( AmgVector(5)  parsID,
const AmgSymMatrix(5)&  covID,
AmgVector(5)  parsMS,
const AmgSymMatrix(5)&  covMS,
int  charge,
AmgVector(5) &  parsCB,
AmgSymMatrix(5) &  covCB,
double &  chi2 
) const
protected

Definition at line 381 of file MuonCalibIntSagittaTool.cxx.

383  {
384  chi2 = 1e20;
385  parsID[4] = std::abs(parsID[4]);
386  parsMS[4] = std::abs(parsMS[4]);
387 
388 
389  Eigen::FullPivLU<AmgSymMatrix(5)> matID(covID);
390  if (!matID.isInvertible()) {
391  ATH_MSG_DEBUG(" ID weight matrix computation failed ");
392  return CorrectionCode::Error;
393  }
394  const AmgSymMatrix(5) weightID = matID.inverse();
395 
396 
397  Eigen::FullPivLU<AmgSymMatrix(5)> matMS(covMS);
398  if (!matMS.isInvertible()) {
399  ATH_MSG_DEBUG(" MS weight matrix computation failed ");
400  return CorrectionCode::Error;
401  }
402  const AmgSymMatrix(5) weightMS = matMS.inverse();
403 
404 
405  Eigen::FullPivLU<AmgSymMatrix(5)> matCB(weightID + weightMS);
406  if (!matCB.isInvertible()) {
407  ATH_MSG_DEBUG(" Inversion of weightCB failed ");
408  return CorrectionCode::Error;
409  }
410  covCB = matCB.inverse();
411 
412 
413  Eigen::FullPivLU<AmgSymMatrix(5)> matSum(covID + covMS);
414  if (!matSum.isInvertible()) {
415  ATH_MSG_DEBUG(" Inversion of weightCB failed ");
416  return CorrectionCode::Error;
417  }
418  AmgSymMatrix(5) invCovSum = matSum.inverse();
419 
420 
421  AmgVector(5) diffPars = parsID - parsMS;
422  chi2 = diffPars.transpose() * invCovSum * diffPars;
423  chi2 = chi2 / 5.;
424 
425  parsCB = covCB * (weightID * parsID + weightMS * parsMS);
426  parsCB[4] *= charge;
427 
428  if (parsCB[2] > M_PI)
429  parsCB[2] -= 2. * M_PI;
430  else if (parsCB[2] < -M_PI)
431  parsCB[2] += 2. * M_PI;
432  return CorrectionCode::Ok;
433  }

◆ applySystematicVariation()

StatusCode CP::MuonCalibIntSagittaTool::applySystematicVariation ( const SystematicSet systConfig)
overrideprivatevirtual

effects: configure this tool for the given list of systematic variations.

any requested systematics that are not affecting this tool will be silently ignored (unless they cause other errors). failures: systematic unknown failures: requesting multiple variations on the same systematic (e.g. up & down) failures: requesting an unsupported variation on an otherwise supported systematic (e.g. a 2 sigma variation and the tool only supports 1 sigma variations) failures: unsupported combination of supported systematic failures: other tool specific errors

Implements CP::ISystematicsTool.

Definition at line 568 of file MuonCalibIntSagittaTool.cxx.

569  {
570  return m_Parameters.get(systConfig, m_currentParameters);
571  }

◆ calcSystematicVariation()

StatusCode CP::MuonCalibIntSagittaTool::calcSystematicVariation ( const SystematicSet systConfig,
ParameterSetSagitta param 
) const
protected

Definition at line 483 of file MuonCalibIntSagittaTool.cxx.

484  {
485  param.SagittaRho = MCP::SystVariation::Default;
486  param.SagittaBias = MCP::SystVariation::Default;
487  param.SagittaGlobal = MCP::SystVariation::Default;
488  param.SagittaPtExtra = MCP::SystVariation::Default;
489  param.SagittaDataStat = MCP::SystVariation::Default;
490  param.SagittaEtaSlice = MCP::SystVariation::Default;
491 
492  // Sagitta Rho systematics
493  SystematicVariation syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_RHO");
494 
495  if (syst == SystematicVariation("MUON_SAGITTA_RHO", 1)) param.SagittaRho = MCP::SystVariation::Down;
496  else if (syst == SystematicVariation("MUON_SAGITTA_RHO", -1)) param.SagittaRho = MCP::SystVariation::Up;
497  else if (!syst.empty()) return StatusCode::FAILURE;
498 
499  // Sagitta Residual Bias systematics
500  syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_RESBIAS");
501 
502  if (syst == SystematicVariation("MUON_SAGITTA_RESBIAS", 1)) param.SagittaBias = MCP::SystVariation::Down;
503  else if (syst == SystematicVariation("MUON_SAGITTA_RESBIAS", -1)) param.SagittaBias = MCP::SystVariation::Up;
504  else if (!syst.empty()) return StatusCode::FAILURE;
505 
506  // Sagitta Residual Global Bias systematics
507  syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_GLOBAL");
508 
509  if (syst == SystematicVariation("MUON_SAGITTA_GLOBAL", 1)) param.SagittaGlobal = MCP::SystVariation::Down;
510  else if (syst == SystematicVariation("MUON_SAGITTA_GLOBAL", -1)) param.SagittaGlobal = MCP::SystVariation::Up;
511  else if (!syst.empty()) return StatusCode::FAILURE;
512 
513  // Sagitta Residual Bias systematics pt extrapolation
514  syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_PTEXTRA");
515 
516  if (syst == SystematicVariation("MUON_SAGITTA_PTEXTRA", 1)) param.SagittaPtExtra = MCP::SystVariation::Down;
517  else if (syst == SystematicVariation("MUON_SAGITTA_PTEXTRA", -1)) param.SagittaPtExtra = MCP::SystVariation::Up;
518  else if (!syst.empty()) return StatusCode::FAILURE;
519 
520  // Sagitta Residual Bias systematics
521  syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_RESBIAS_POSETA");
522 
523  if (syst == SystematicVariation("MUON_SAGITTA_RESBIAS_POSETA", 1))
524  {
525  param.SagittaBias = MCP::SystVariation::Down;
526  param.SagittaEtaSlice = MCP::SystVariation::Up;
527  }
528  else if (syst == SystematicVariation("MUON_SAGITTA_RESBIAS_POSETA", -1))
529  {
530  param.SagittaBias = MCP::SystVariation::Up;
531  param.SagittaEtaSlice = MCP::SystVariation::Up;
532  }
533  else if (!syst.empty()) return StatusCode::FAILURE;
534 
535  // Sagitta Residual Bias systematics
536  syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_RESBIAS_NEGETA");
537 
538  if (syst == SystematicVariation("MUON_SAGITTA_RESBIAS_NEGETA", 1))
539  {
540  param.SagittaBias = MCP::SystVariation::Down;
541  param.SagittaEtaSlice = MCP::SystVariation::Down;
542  }
543  else if (syst == SystematicVariation("MUON_SAGITTA_RESBIAS_NEGETA", -1))
544  {
545  param.SagittaBias = MCP::SystVariation::Up;
546  param.SagittaEtaSlice = MCP::SystVariation::Down;
547  }
548  else if (!syst.empty()) return StatusCode::FAILURE;
549 
550  // Sagitta Residual Bias systematics
551  syst = systConfig.getSystematicByBaseName("MUON_SAGITTA_DATASTAT");
552 
553  if (syst == SystematicVariation("MUON_SAGITTA_DATASTAT", 1)) param.SagittaDataStat = MCP::SystVariation::Up;
554  else if (syst == SystematicVariation("MUON_SAGITTA_DATASTAT", -1)) param.SagittaDataStat = MCP::SystVariation::Down;
555  else if (!syst.empty()) return StatusCode::FAILURE;
556 
557  //
558  ATH_MSG_DEBUG("Systematic variation's parameters, SagittaRho: " << param.SagittaRho);
559  ATH_MSG_DEBUG("Systematic variation's parameters, SagittaBias: " << param.SagittaBias);
560  ATH_MSG_DEBUG("Systematic variation's parameters, SagittaGlobal: " << param.SagittaGlobal);
561  ATH_MSG_DEBUG("Systematic variation's parameters, SagittaPtExtra: " << param.SagittaPtExtra);
562  ATH_MSG_DEBUG("Systematic variation's parameters, SagittaDataStat: " << param.SagittaDataStat);
563  ATH_MSG_DEBUG("Systematic variation's parameters, SagittaEtaSlice: " << param.SagittaEtaSlice);
564 
565  return StatusCode::SUCCESS;
566  }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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< AlgTool > >::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; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::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

◆ getCorrections()

std::vector< double > CP::MuonCalibIntSagittaTool::getCorrections ( const MCP::TrackCalibObj mu) const
protected

Definition at line 148 of file MuonCalibIntSagittaTool.cxx.

149  {
150  double eta = trk.eta;
151  double pT = trk.calib_pt;
152  SagittaCorrConstMap const *corrMap{nullptr};
153  SagittaCorrConstMap const *kinematicTermMap{nullptr};
154  if(trk.type == MCP::TrackType::CB)
155  {
156  corrMap = &m_sagittaCorrConst_CB.at(trk.year);
157  kinematicTermMap = &m_sagittaCorrConst_mcCB.at(trk.year);
158  }
159  else if(trk.type == MCP::TrackType::ID)
160  {
161  corrMap = &m_sagittaCorrConst_ID.at(trk.year);
162  kinematicTermMap = &m_sagittaCorrConst_mcID.at(trk.year);
163  }
164  else if(trk.type == MCP::TrackType::ME)
165  {
166  corrMap = &m_sagittaCorrConst_ME.at(trk.year);
167  kinematicTermMap = &m_sagittaCorrConst_mcME.at(trk.year);
168  }
169 
170  std::vector<double> corrections;
171  if(trk.isData)
172  {
173  if(!m_applyCorrectionOnData) return corrections;
174  else if (m_applyCorrectionOnData)
175  {
176  // Apply data - kinematic term for the nominal
177  double corr = corrMap->at(MCP::SagittaCorrection::Nominal)->getCalibConstant(trk);
178  corr -= kinematicTermMap->at(MCP::SagittaCorrection::Nominal)->getCalibConstant(trk);
179  corrections.push_back(corr);
180  }
181  }
182  else // if it is MC
183  {
184  // Otherwise do as needed
186  {
188  // Sanity check
190  {
191  ATH_MSG_ERROR("Sagitta correction is not applied to data, yet Eta dependant systematics are requested. This configuration is not supported");
192  return corrections;
193  }
194 
195  // if no apply correction on data, apply 100% of (Data - kinematic term)
196  // TODO: Check if it 50% or 100%?
198  {
199  // Apply data - kinematic term for the nominal
200  double corr = corrMap->at(MCP::SagittaCorrection::Nominal)->getCalibConstant(trk);
201  ATH_MSG_VERBOSE("Raw corr: "<<corr);
202  // corr -= kinematicTermMap->at(MCP::SagittaCorrection::Nominal)->getCalibConstant(eta, phi);
203  // ATH_MSG_VERBOSE("Raw - Kinematic corr: "<<corr);
204  corr *= (scale);
205  ATH_MSG_VERBOSE("corr: "<<corr);
206  corrections.push_back(corr);
207  }
208 
209  // 100% of resbiasMap added as res bias
210  double corr = corrMap->at(MCP::SagittaCorrection::Residual__1up)->getCalibConstant(trk);
211  corr *= scale;
212  ATH_MSG_VERBOSE("Residual corr: "<<corr);
213 
214  // If eta dependant, set the p2 to 0, if it not in the given eta slices
215  if ((m_currentParameters->SagittaEtaSlice == MCP::SystVariation::Up) && eta < 0) corr = 0;
216  if ((m_currentParameters->SagittaEtaSlice == MCP::SystVariation::Down) && eta > 0) corr = 0;
217 
218  corrections.push_back(corr);
219  ATH_MSG_VERBOSE("final corr: "<<corr);
220  }
222  {
224 
225  double deltas = m_extraRebiasSys;
226  // systematic for Run3 data 2022
227  if (trk.year==MCP::DataYear::Data22) {
228  if(m_release.value().find("Recs2023") != std::string::npos) deltas = 1.2 * deltas;
229  else if(std::abs(eta)>1.05) deltas = 1.5 * deltas;
230  }
231  double corr = deltas * scale;
232  ATH_MSG_VERBOSE("Deltas corr: "<<deltas);
233 
234  corrections.push_back(corr);
235  ATH_MSG_VERBOSE("final corr: "<<corr);
236 
237  }
239  {
241 
242  // Extra scaling to cover for non-closure in the forward and transition region
243  // As seen in the Rel 21 validation of the sagitta correction
244  // It is only concetrateed in a few high eta bin. Idea is to apply a linearly increasing sys
245  // Till it reach 450 GeV and then to flatten it.
246  // The value is chosen in an arbitrary fashion. To be replaced and fixed, once we have a better idea of
247  double corr = 0;
248  double deltas = 0.00002;
249  if (eta > 2 || (eta > -2 && eta < -1.05)) {
250  if (pT > 450.0)
251  corr += std::abs(450.0 - 45) / 100 * deltas; // Above 450 GeV flat
252  else
253  corr += std::abs(pT - 45) / 100 * deltas;
254  }
255  if (eta < -2 || (eta < 2 && eta> 1.5)) {
256  if (pT > 450.0)
257  corr += std::abs(450.0 - 45) / 200 * deltas; // Above 450 GeV flat
258  else
259  corr += std::abs(pT - 45) / 200 * deltas;
260  }
261  // additional uncertainties for 2022 data
262  if (m_release.value().find("Recs2023") != std::string::npos) {
263  if ( (trk.year==MCP::DataYear::Data22) && pT > 100.0) {
264  if (eta < 0 && eta> -0.5) corr += 2.1*deltas;
265  else if (eta < -1.05) corr += 1.1*deltas;
266  else if (eta > 0.5 ) corr += 0.8*deltas;
267  }
268  } else {
269  if ( trk.year==MCP::DataYear::Data22 ) {
270  if (eta > -2 && eta < -1.05) corr = corr*2.5;
271  if (eta < -2) corr = corr*6;
272  if (eta > 1.5 && eta < 2) {
273  if (pT > 450.0)
274  corr += std::abs(450.0 - 45) / 80 * deltas; // Above 450 GeV flat
275  else
276  corr += std::abs(pT - 45) / 80 * deltas;
277  }
278  if (eta > 1.05 && eta < 1.5) {
279  if (pT > 450.0)
280  corr += std::abs(450.0 - 45) / 40 * deltas; // Above 450 GeV flat
281  else
282  corr += std::abs(pT - 45) / 40 * deltas;
283  }
284  }
285  }
286  ATH_MSG_VERBOSE("Deltas corr: "<<deltas);
287 
288 
289  corrections.push_back(corr*scale);
290  ATH_MSG_VERBOSE("final corr: "<<corr);
291 
292  }
294  {
296  // Apply 50% of the datastat map, up and down as stat error
297  // TODO change to 100%
298  // -1 is to match the convention
299  double corr = corrMap->at(MCP::SagittaCorrection::Datastat__1up)->getCalibConstant(trk);
300  corr *= (0.5 * scale);
301  ATH_MSG_VERBOSE("data stat final corr: "<<corr);
302  corrections.push_back(corr);
303  }
305  {
306  // For rho systematic, nothing happens right now
307  }
308  else
309  {
310  // if it is MC, then for nominal corrections - we don't apply anything
311  }
312  }
313 
314  return corrections;
315  }

◆ getKey()

SG::sgkey_t asg::AsgTool::getKey ( const void *  ptr) const
inherited

Get the (hashed) key of an object that is in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getName
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The hashed key of the object in the store. If not found, an invalid (zero) key.

Definition at line 119 of file AsgTool.cxx.

119  {
120 
121 #ifdef XAOD_STANDALONE
122  // In case we use @c xAOD::TEvent, we have a direct function call
123  // for this.
124  return evtStore()->event()->getKey( ptr );
125 #else
126  const SG::DataProxy* proxy = evtStore()->proxy( ptr );
127  return ( proxy == nullptr ? 0 : proxy->sgkey() );
128 #endif // XAOD_STANDALONE
129  }

◆ getName()

const std::string & asg::AsgTool::getName ( const void *  ptr) const
inherited

Get the name of an object that is / should be in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::TEvent both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getKey
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The string name of the object in the store. If not found, an empty string.

Definition at line 106 of file AsgTool.cxx.

106  {
107 
108 #ifdef XAOD_STANDALONE
109  // In case we use @c xAOD::TEvent, we have a direct function call
110  // for this.
111  return evtStore()->event()->getName( ptr );
112 #else
113  const SG::DataProxy* proxy = evtStore()->proxy( ptr );
114  static const std::string dummy = "";
115  return ( proxy == nullptr ? dummy : proxy->name() );
116 #endif // XAOD_STANDALONE
117  }

◆ getProperty()

template<class T >
const T* asg::AsgTool::getProperty ( const std::string &  name) const
inherited

Get one of the tool's properties.

◆ initialize()

StatusCode CP::MuonCalibIntSagittaTool::initialize ( )
overridevirtual

Dummy implementation of the initialisation function.

It's here to allow the dual-use tools to skip defining an initialisation function. Since many are doing so...

Reimplemented from asg::AsgTool.

Definition at line 23 of file MuonCalibIntSagittaTool.cxx.

24  {
25  // Greet the user:
26  ATH_MSG_INFO("Initializing MuonCalibIntSagittaTool");
27 
28  // Get the m_eventinfo container
30 
31  // Read the recommendations
32  for(const auto& year: MCP::dataYearList)
33  {
37 
38  // Corrections from the MC - what is typically referred to as the kinematic term
42  ATH_MSG_VERBOSE("Sagitta initilised: Year " <<m_release);
43  }
44 
45  m_currentParameters = nullptr;
46  // Init the systematics
47  m_Parameters.initialize(affectingSystematics(), [this](const SystematicSet &systConfig, ParameterSetSagitta &param)
48  { return calcSystematicVariation(systConfig, param); });
49  if (!applySystematicVariation(SystematicSet()))
50  {
51  ATH_MSG_ERROR("Unable to run with no systematic");
52  return StatusCode::FAILURE;
53  }
54  SystematicRegistry &registry = SystematicRegistry::getInstance();
55  if (registry.registerSystematics(*this) != StatusCode::SUCCESS)
56  {
57  ATH_MSG_ERROR("Unkown systematic list");
58  return StatusCode::FAILURE;
59  }
60  // Return gracefully:
61  return StatusCode::SUCCESS;
62  }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::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.

◆ isAffectedBySystematic()

bool CP::MuonCalibIntSagittaTool::isAffectedBySystematic ( const SystematicVariation systematic) const
overrideprivatevirtual

Declare the interface that this class provides.

returns: whether this tool is affected by the given systematics

Implements CP::ISystematicsTool.

Definition at line 437 of file MuonCalibIntSagittaTool.cxx.

438  {
439  SystematicSet sys = affectingSystematics();
440  return sys.find(systematic) != sys.end();
441  }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

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

Definition at line 27 of file AthCommonMsg.h.

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

◆ msg_level_name()

const std::string & asg::AsgTool::msg_level_name ( ) const
inherited

A deprecated function for getting the message level's name.

Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:

MSG::name( msg().level() )

This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.

Returns
The string name of the current minimum message level that's printed

Definition at line 101 of file AsgTool.cxx.

101  {
102 
103  return MSG::name( msg().level() );
104  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::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< AlgTool > >::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.

◆ print() [1/2]

void asg::AsgTool::print ( ) const
virtualinherited

◆ print() [2/2]

virtual void asg::IAsgTool::print ( ) const
pure virtualinherited

◆ recommendedSystematics()

SystematicSet CP::MuonCalibIntSagittaTool::recommendedSystematics ( ) const
overrideprivatevirtual

the list of all systematics this tool recommends to use

Implements CP::IReentrantSystematicsTool.

Definition at line 481 of file MuonCalibIntSagittaTool.cxx.

481 { return affectingSystematics(); }

◆ 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< AlgTool > >::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< AlgTool > >::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  }

◆ statCombCorrection()

double CP::MuonCalibIntSagittaTool::statCombCorrection ( const MCP::MuonObj mu,
double  corrIDpT,
double  corrMEpT,
double  CBpT 
) const
protected

Definition at line 318 of file MuonCalibIntSagittaTool.cxx.

319  {
320  ATH_MSG_VERBOSE("Sag mu.ID.calib_pt: "<<mu.ID.calib_pt);
321  ATH_MSG_VERBOSE("Sag mu.ME.calib_pt: "<<mu.ME.calib_pt);
322  ATH_MSG_VERBOSE("Sag mu.CB.calib_pt: "<<mu.CB.calib_pt);
323 
324  // Corner cases to prevent a NaN in the combination
325  if(mu.ID.calib_pt == 0) return CBpT;
326  if(mu.ME.calib_pt == 0) return CBpT;
327  if(corrIDpT == 0) return CBpT;
328  if(corrMEpT == 0) return CBpT;
329 
330  double chi2Nom = -999;
331  AmgVector(5) parsCBNom = mu.CB.pars;
332  AmgVector(5) parsID = mu.ID.pars;
333  AmgVector(5) parsMS = mu.ME.pars;
334  AmgSymMatrix(5) covCBNom = mu.CB.covariance;
335  AmgSymMatrix(5) covID = mu.ID.covariance;
336  AmgSymMatrix(5) covMS = mu.ME.covariance;
337 
338  AmgVector(5) parsCBCorr;
339  AmgSymMatrix(5) covCBCorr;
340 
341  // Do the statistical combination, with the original pTs
342  // create the TLV with original ID pT
343  using TLV = ROOT::Math::LorentzVector<ROOT::Math::PtEtaPhiM4D<double>>;
344  TLV tlv{mu.ID.calib_pt, mu.ID.eta, mu.ID.phi, mu.ID.mass};
345  // Now modify the ID covariance matrix, and convert it to MeV
346  if(tlv.P() == 0) parsID[4] = 1e12;
347  else parsID[4] = 1.0 / (tlv.P() * 1e3);
348 
349  tlv.SetCoordinates(mu.ME.calib_pt, mu.ME.eta, mu.ME.phi, mu.ME.mass);
350  // Now modify the ME covariance matrix
351  if(tlv.P() == 0) parsMS[4] = 1e12;
352  else parsMS[4] = 1.0 / (tlv.P() * 1e3);
353 
354  CorrectionCode SysCorrCode = applyStatCombination(parsID, covID, parsMS, covMS, mu.CB.calib_charge, parsCBNom, covCBNom, chi2Nom);
355  if (SysCorrCode != CorrectionCode::Ok) return CBpT;
356 
357 
358  // Do the statistical combination, with the original pTs
359  // create the TLV with original ID pT
360  tlv.SetCoordinates(corrIDpT, mu.ID.eta, mu.ID.phi, mu.ID.mass);
361  // Now modify the ID covariance matrix, and convert it to MeV
362  if(tlv.P() == 0) parsID[4] = 1e12;
363  else parsID[4] = 1.0 / (tlv.P() * 1e3);
364 
365  tlv.SetCoordinates(corrMEpT, mu.ME.eta, mu.ME.phi, mu.ME.mass);
366  // Now modify the ME covariance matrix
367  if(tlv.P() == 0) parsMS[4] = 1e12;
368  else parsMS[4] = 1.0 / (tlv.P() * 1e3);
369 
370  SysCorrCode = applyStatCombination(parsID, covID, parsMS, covMS, mu.CB.calib_charge, parsCBCorr, covCBCorr, chi2Nom);
371  if (SysCorrCode != CorrectionCode::Ok) return CBpT;
372 
373 
374  double statCombPtNom = std::sin(parsCBNom[3]) / std::abs(parsCBNom[4]);
375  double statCombPtCorr = std::sin(parsCBCorr[3]) / std::abs(parsCBCorr[4]);
376  double corrCBpT = CBpT * (statCombPtCorr / statCombPtNom);
377 
378  return corrCBpT;
379 
380  }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::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< AlgTool > >::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_applyCorrectionOnData

Gaudi::Property<bool> CP::MuonCalibIntSagittaTool::m_applyCorrectionOnData {this, "applyCorrectionOnData", true, "If to apply sagitta corrections on data, or take the full effect as systematic"}
protected

Definition at line 66 of file MuonCalibIntSagittaTool.h.

◆ m_currentParameters

const ParameterSetSagitta* CP::MuonCalibIntSagittaTool::m_currentParameters {nullptr}
protected

Definition at line 93 of file MuonCalibIntSagittaTool.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doDirectCBCalib

Gaudi::Property<bool> CP::MuonCalibIntSagittaTool::m_doDirectCBCalib {this, "doDirectCBCalib", true, "Apply sagitta corrections on CB tracks, otherwise, on ID+MS"}
protected

Definition at line 69 of file MuonCalibIntSagittaTool.h.

◆ m_doEtaSagittaSys

Gaudi::Property<bool> CP::MuonCalibIntSagittaTool::m_doEtaSagittaSys {this, "doEtaSagittaSys", false, "Do Eta dependant systematic system"}
protected

Definition at line 65 of file MuonCalibIntSagittaTool.h.

◆ m_eventInfo

SG::ReadHandleKey<xAOD::EventInfo> CP::MuonCalibIntSagittaTool::m_eventInfo {this, "EventInfoContName", "EventInfo", "event info key"}
protected

Definition at line 59 of file MuonCalibIntSagittaTool.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_extraRebiasSys

Gaudi::Property<float> CP::MuonCalibIntSagittaTool::m_extraRebiasSys {this, "extraRebias", 0.00002, "Additional systematic applied for the residual bias observed"}
protected

Definition at line 77 of file MuonCalibIntSagittaTool.h.

◆ m_fixedRhoValue

Gaudi::Property<float> CP::MuonCalibIntSagittaTool::m_fixedRhoValue {this, "fixedRhoValue", 1, "Value for rho, if it is forced"}
protected

Definition at line 73 of file MuonCalibIntSagittaTool.h.

◆ m_Parameters

SystematicsCache<ParameterSetSagitta> CP::MuonCalibIntSagittaTool::m_Parameters {this}
protected

Definition at line 92 of file MuonCalibIntSagittaTool.h.

◆ m_release

Gaudi::Property<std::string> CP::MuonCalibIntSagittaTool::m_release {this, "release", "Recs2024_05_06_Run2Run3", "Release"}
protected

Definition at line 62 of file MuonCalibIntSagittaTool.h.

◆ m_sagittaCorrConst_CB

std::map<MCP::DataYear, SagittaCorrConstMap> CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_CB
protected

Definition at line 100 of file MuonCalibIntSagittaTool.h.

◆ m_sagittaCorrConst_ID

std::map<MCP::DataYear, SagittaCorrConstMap> CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_ID
protected

Definition at line 98 of file MuonCalibIntSagittaTool.h.

◆ m_sagittaCorrConst_mcCB

std::map<MCP::DataYear, SagittaCorrConstMap> CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_mcCB
protected

Definition at line 105 of file MuonCalibIntSagittaTool.h.

◆ m_sagittaCorrConst_mcID

std::map<MCP::DataYear, SagittaCorrConstMap> CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_mcID
protected

Definition at line 103 of file MuonCalibIntSagittaTool.h.

◆ m_sagittaCorrConst_mcME

std::map<MCP::DataYear, SagittaCorrConstMap> CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_mcME
protected

Definition at line 104 of file MuonCalibIntSagittaTool.h.

◆ m_sagittaCorrConst_ME

std::map<MCP::DataYear, SagittaCorrConstMap> CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_ME
protected

Definition at line 99 of file MuonCalibIntSagittaTool.h.

◆ m_sysScheme

Gaudi::Property<std::string> CP::MuonCalibIntSagittaTool::m_sysScheme {this, "systematicScheme", "Corr_Scale", "Systematic scheme to be configured"}
protected

Definition at line 76 of file MuonCalibIntSagittaTool.h.

◆ m_useFixedRho

Gaudi::Property<bool> CP::MuonCalibIntSagittaTool::m_useFixedRho {this, "useFixedRho", true, "Force Fixed Rho"}
protected

Definition at line 72 of file MuonCalibIntSagittaTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

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

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
python.Dso.registry
registry
Definition: Control/AthenaServices/python/Dso.py:159
CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_mcCB
std::map< MCP::DataYear, SagittaCorrConstMap > m_sagittaCorrConst_mcCB
Definition: MuonCalibIntSagittaTool.h:105
make_hlt_rep.pars
pars
Definition: make_hlt_rep.py:90
CalculateHighPtTerm.pT
pT
Definition: ICHEP2016/CalculateHighPtTerm.py:57
test_pyathena.eta
eta
Definition: test_pyathena.py:10
MCP::SagittaCorrection::Residual__1up
@ Residual__1up
CP::MuonCalibIntSagittaTool::ParameterSetSagitta::SagittaBias
double SagittaBias
Definition: MuonCalibIntSagittaTool.h:82
asg::AsgTool
Base class for the dual-use tool implementation classes.
Definition: AsgTool.h:47
MCP::SystVariation::Up
@ Up
Definition: EnumDef.h:73
get_generator_info.result
result
Definition: get_generator_info.py:21
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:392
CP::MuonCalibIntSagittaTool::m_useFixedRho
Gaudi::Property< bool > m_useFixedRho
Definition: MuonCalibIntSagittaTool.h:72
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
ID
std::vector< Identifier > ID
Definition: CalibHitIDCheck.h:24
CP::MuonCalibIntSagittaTool::ParameterSetSagitta::SagittaDataStat
double SagittaDataStat
Definition: MuonCalibIntSagittaTool.h:85
CP::MuonCalibIntSagittaTool::calcSystematicVariation
StatusCode calcSystematicVariation(const SystematicSet &systConfig, ParameterSetSagitta &param) const
Definition: MuonCalibIntSagittaTool.cxx:483
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_CB
std::map< MCP::DataYear, SagittaCorrConstMap > m_sagittaCorrConst_CB
Definition: MuonCalibIntSagittaTool.h:100
CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_ID
std::map< MCP::DataYear, SagittaCorrConstMap > m_sagittaCorrConst_ID
Definition: MuonCalibIntSagittaTool.h:98
CP::MuonCalibIntSagittaTool::ParameterSetSagitta::SagittaPtExtra
double SagittaPtExtra
Definition: MuonCalibIntSagittaTool.h:84
CP::MuonCalibIntSagittaTool::m_eventInfo
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfo
Definition: MuonCalibIntSagittaTool.h:59
test_pyathena.pt
pt
Definition: test_pyathena.py:11
M_PI
#define M_PI
Definition: ActiveFraction.h:11
CP::MuonCalibIntSagittaTool::m_sysScheme
Gaudi::Property< std::string > m_sysScheme
Definition: MuonCalibIntSagittaTool.h:76
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
CP::MuonCalibIntSagittaTool::m_extraRebiasSys
Gaudi::Property< float > m_extraRebiasSys
Definition: MuonCalibIntSagittaTool.h:77
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
CP::MuonCalibIntSagittaTool::m_doEtaSagittaSys
Gaudi::Property< bool > m_doEtaSagittaSys
Definition: MuonCalibIntSagittaTool.h:65
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
python.AtlRunQueryAMI.year
year
Definition: AtlRunQueryAMI.py:226
yodamerge_tmp.scale
scale
Definition: yodamerge_tmp.py:138
CP::MuonCalibIntSagittaTool::affectingSystematics
virtual SystematicSet affectingSystematics() const override
the list of all systematics this tool can be affected by
Definition: MuonCalibIntSagittaTool.cxx:443
AmgSymMatrix
#define AmgSymMatrix(dim)
Definition: EventPrimitives.h:50
mapkey::sys
@ sys
Definition: TElectronEfficiencyCorrectionTool.cxx:42
CP::MuonCalibIntSagittaTool::ParameterSetSagitta::SagittaRho
double SagittaRho
Definition: MuonCalibIntSagittaTool.h:81
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
CP::MuonCalibIntSagittaTool::m_release
Gaudi::Property< std::string > m_release
Definition: MuonCalibIntSagittaTool.h:62
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
CP::MuonCalibIntSagittaTool::applyStatCombination
CorrectionCode applyStatCombination(AmgVector(5) parsID, const AmgSymMatrix(5)&covID, AmgVector(5) parsMS, const AmgSymMatrix(5)&covMS, int charge, AmgVector(5) &parsCB, AmgSymMatrix(5) &covCB, double &chi2) const
Definition: MuonCalibIntSagittaTool.cxx:381
MCP::SagittaCorrection::Datastat__1up
@ Datastat__1up
tools.zlumi_mc_cf.correction
def correction(mu, runmode, campaign, run=None)
Definition: zlumi_mc_cf.py:4
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
CP::CorrectionCode::Error
@ Error
Some error happened during the object correction.
Definition: CorrectionCode.h:36
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
MCP::SystVariation::Default
@ Default
Definition: EnumDef.h:73
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
CheckAppliedSFs.e3
e3
Definition: CheckAppliedSFs.py:264
MuonR4::inverse
CalibratedSpacePoint::Covariance_t inverse(const CalibratedSpacePoint::Covariance_t &mat)
Inverts the parsed matrix.
Definition: MuonSpectrometer/MuonPhaseII/Event/MuonSpacePoint/src/UtilFunctions.cxx:65
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
AmgVector
AmgVector(4) T2BSTrackFilterTool
Definition: T2BSTrackFilterTool.cxx:114
CP::MuonCalibIntSagittaTool::m_Parameters
SystematicsCache< ParameterSetSagitta > m_Parameters
Definition: MuonCalibIntSagittaTool.h:92
chi2
double chi2(TH1 *h0, TH1 *h1)
Definition: comparitor.cxx:523
CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_mcME
std::map< MCP::DataYear, SagittaCorrConstMap > m_sagittaCorrConst_mcME
Definition: MuonCalibIntSagittaTool.h:104
python.xAODType.dummy
dummy
Definition: xAODType.py:4
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
MSG::name
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition: MsgLevel.cxx:19
AthCommonDataStore< AthCommonMsg< AlgTool > >::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
CP::MuonCalibIntSagittaTool::ParameterSetSagitta::SagittaEtaSlice
double SagittaEtaSlice
Definition: MuonCalibIntSagittaTool.h:86
CP::MuonCalibIntSagittaTool::applySystematicVariation
virtual StatusCode applySystematicVariation(const SystematicSet &systConfig) override
effects: configure this tool for the given list of systematic variations.
Definition: MuonCalibIntSagittaTool.cxx:568
CP::MuonCalibIntSagittaTool::SagittaCorrConstMap
std::map< MCP::SagittaCorrection, std::shared_ptr< MCP::CalibContainer > > SagittaCorrConstMap
Definition: MuonCalibIntSagittaTool.h:95
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_mcID
std::map< MCP::DataYear, SagittaCorrConstMap > m_sagittaCorrConst_mcID
Definition: MuonCalibIntSagittaTool.h:103
CP::MuonCalibIntSagittaTool::ParameterSetSagitta::SagittaGlobal
double SagittaGlobal
Definition: MuonCalibIntSagittaTool.h:83
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
charge
double charge(const T &p)
Definition: AtlasPID.h:756
CP::MuonCalibIntSagittaTool::m_sagittaCorrConst_ME
std::map< MCP::DataYear, SagittaCorrConstMap > m_sagittaCorrConst_ME
Definition: MuonCalibIntSagittaTool.h:99
MCP::TrackType::CB
@ CB
CP::MuonCalibIntSagittaTool::m_applyCorrectionOnData
Gaudi::Property< bool > m_applyCorrectionOnData
Definition: MuonCalibIntSagittaTool.h:66
MCP::SagittaCorrection::Nominal
@ Nominal
CP::CorrectionCode::Ok
@ Ok
The correction was done successfully.
Definition: CorrectionCode.h:38
a
TList * a
Definition: liststreamerinfos.cxx:10
h
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
if
if(febId1==febId2)
Definition: LArRodBlockPhysicsV0.cxx:567
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
MCP::CalibInitializer::createSagittaCorrMap
std::map< SagittaCorrection, std::shared_ptr< CalibContainer > > createSagittaCorrMap(DataYear dataYear, TrackType type, const std::string &recommendationPath, const std::string &correctionType)
Definition: CalibInitializer.cxx:13
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
SG::DataProxy
Definition: DataProxy.h:45
CaloNoise_fillDB.mu
mu
Definition: CaloNoise_fillDB.py:53
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
ROOT
Selection rules: declare transient members.
Definition: DataVector.h:580
MCP::DataYear::Data22
@ Data22
MCP::TrackType::ME
@ ME
MCP::SystVariation::Down
@ Down
Definition: EnumDef.h:73
fitman.k
k
Definition: fitman.py:528
CP::SystematicRegistry::getInstance
static SystematicRegistry & getInstance()
Get the singleton instance of the registry for the curren thread.
Definition: SystematicRegistry.cxx:25
MCP::TrackType::ID
@ ID
CP::MuonCalibIntSagittaTool::m_currentParameters
const ParameterSetSagitta * m_currentParameters
Definition: MuonCalibIntSagittaTool.h:93