ATLAS Offline Software
Typedefs | Functions
TauGNNUtils::Variables::Cluster Namespace Reference

Typedefs

using MomentType = xAOD::CaloCluster::MomentType
 

Functions

bool et_log (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool pt_tau_log (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &, float &out)
 
bool pt_jetseed_log (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &, float &out)
 
bool dEta (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool dPhi (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool SECOND_R (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool SECOND_LAMBDA (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool CENTER_LAMBDA (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool SECOND_LAMBDAOverClustersMeanSecondLambda (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool CENTER_LAMBDAOverClustersMeanCenterLambda (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool FirstEngDensOverClustersMeanFirstEngDens (const xAOD::TauJet &tau, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool e (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool et (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool FIRST_ENG_DENS (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool EM_PROBABILITY (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 
bool CENTER_MAG (const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
 

Typedef Documentation

◆ MomentType

Definition at line 683 of file TauGNNUtils.cxx.

Function Documentation

◆ CENTER_LAMBDA()

bool TauGNNUtils::Variables::Cluster::CENTER_LAMBDA ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 724 of file TauGNNUtils.cxx.

724  {
725  double double_out;
726  const auto success = cluster.clust().retrieveMoment(MomentType::CENTER_LAMBDA, double_out);
727  out = static_cast<float>(double_out);
728  return success;
729 }

◆ CENTER_LAMBDAOverClustersMeanCenterLambda()

bool TauGNNUtils::Variables::Cluster::CENTER_LAMBDAOverClustersMeanCenterLambda ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 740 of file TauGNNUtils.cxx.

740  {
741  static const SG::ConstAccessor<float> acc_ClustersMeanCenterLambda("ClustersMeanCenterLambda");
742  float ClustersMeanCenterLambda = acc_ClustersMeanCenterLambda(tau);
743  double centerLambda(0);
744  const auto success = cluster.clust().retrieveMoment(MomentType::CENTER_LAMBDA, centerLambda);
745  if (ClustersMeanCenterLambda == 0.){
746  out = 250.;
747  }else {
748  out = centerLambda/ClustersMeanCenterLambda;
749  }
750 
751  out = std::min(out, 250.0f);
752 
753  return success;
754 }

◆ CENTER_MAG()

bool TauGNNUtils::Variables::Cluster::CENTER_MAG ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 802 of file TauGNNUtils.cxx.

802  {
803  double clusterCenterMag = 0.0;
804  bool status = cluster.clust().retrieveMoment(MomentType::CENTER_MAG, clusterCenterMag);
805  out = clusterCenterMag;
806  return status;
807 }

◆ dEta()

bool TauGNNUtils::Variables::Cluster::dEta ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 700 of file TauGNNUtils.cxx.

700  {
701  out = cluster.eta() - tau.eta();
702  return true;
703 }

◆ dPhi()

bool TauGNNUtils::Variables::Cluster::dPhi ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 705 of file TauGNNUtils.cxx.

705  {
706  out = cluster.p4().DeltaPhi(tau.p4());
707  return true;
708 }

◆ e()

bool TauGNNUtils::Variables::Cluster::e ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 778 of file TauGNNUtils.cxx.

778  {
779  out = cluster.p4().E();
780  return true;
781 }

◆ EM_PROBABILITY()

bool TauGNNUtils::Variables::Cluster::EM_PROBABILITY ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 795 of file TauGNNUtils.cxx.

795  {
796  double clusterEMprob = 0.0;
797  bool status = cluster.clust().retrieveMoment(MomentType::EM_PROBABILITY, clusterEMprob);
798  out = clusterEMprob;
799  return status;
800 }

◆ et()

bool TauGNNUtils::Variables::Cluster::et ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 783 of file TauGNNUtils.cxx.

783  {
784  out = cluster.p4().Et();
785  return true;
786 }

◆ et_log()

bool TauGNNUtils::Variables::Cluster::et_log ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 685 of file TauGNNUtils.cxx.

685  {
686  out = std::log10(cluster.p4().Et());
687  return true;
688 }

◆ FIRST_ENG_DENS()

bool TauGNNUtils::Variables::Cluster::FIRST_ENG_DENS ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 788 of file TauGNNUtils.cxx.

788  {
789  double clusterFirstEngDens = 0.0;
790  bool status = cluster.clust().retrieveMoment(MomentType::FIRST_ENG_DENS, clusterFirstEngDens);
791  out = clusterFirstEngDens;
792  return status;
793 }

◆ FirstEngDensOverClustersMeanFirstEngDens()

bool TauGNNUtils::Variables::Cluster::FirstEngDensOverClustersMeanFirstEngDens ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 757 of file TauGNNUtils.cxx.

757  {
758  // the ClustersMeanFirstEngDens is the log10 of the energy weighted average of the First_ENG_DENS
759  // divided by ETot to make it dimension-less,
760  // so we need to evaluate the difference of log10(clusterFirstEngDens/clusterTotalEnergy) and the ClustersMeanFirstEngDens
761  double clusterFirstEngDens = 0.0;
762  bool status = cluster.clust().retrieveMoment(MomentType::FIRST_ENG_DENS, clusterFirstEngDens);
763  if (clusterFirstEngDens < 1e-6) clusterFirstEngDens = 1e-6;
764 
765  static const SG::ConstAccessor<float> acc_ClusterTotalEnergy("ClusterTotalEnergy");
766  float clusterTotalEnergy = acc_ClusterTotalEnergy(tau);
767  if (clusterTotalEnergy < 1e-6) clusterTotalEnergy = 1e-6;
768 
769  static const SG::ConstAccessor<float> acc_ClustersMeanFirstEngDens("ClustersMeanFirstEngDens");
770  float clustersMeanFirstEngDens = acc_ClustersMeanFirstEngDens(tau);
771 
772  out = std::log10(clusterFirstEngDens/clusterTotalEnergy) - clustersMeanFirstEngDens;
773 
774  return status;
775 }

◆ pt_jetseed_log()

bool TauGNNUtils::Variables::Cluster::pt_jetseed_log ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster ,
float &  out 
)

Definition at line 695 of file TauGNNUtils.cxx.

695  {
696  out = std::log10(tau.ptJetSeed());
697  return true;
698 }

◆ pt_tau_log()

bool TauGNNUtils::Variables::Cluster::pt_tau_log ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster ,
float &  out 
)

Definition at line 690 of file TauGNNUtils.cxx.

690  {
691  out = std::log10(std::max(tau.pt(), 1e-6));
692  return true;
693 }

◆ SECOND_LAMBDA()

bool TauGNNUtils::Variables::Cluster::SECOND_LAMBDA ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 717 of file TauGNNUtils.cxx.

717  {
718  double double_out;
719  const auto success = cluster.clust().retrieveMoment(MomentType::SECOND_LAMBDA, double_out);
720  out = static_cast<float>(double_out);
721  return success;
722 }

◆ SECOND_LAMBDAOverClustersMeanSecondLambda()

bool TauGNNUtils::Variables::Cluster::SECOND_LAMBDAOverClustersMeanSecondLambda ( const xAOD::TauJet tau,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 731 of file TauGNNUtils.cxx.

731  {
732  static const SG::ConstAccessor<float> acc_ClustersMeanSecondLambda("ClustersMeanSecondLambda");
733  float ClustersMeanSecondLambda = acc_ClustersMeanSecondLambda(tau);
734  double secondLambda(0);
735  const auto success = cluster.clust().retrieveMoment(MomentType::SECOND_LAMBDA, secondLambda);
736  out = (ClustersMeanSecondLambda != 0.) ? secondLambda/ClustersMeanSecondLambda : 0.;
737  return success;
738 }

◆ SECOND_R()

bool TauGNNUtils::Variables::Cluster::SECOND_R ( const xAOD::TauJet ,
const xAOD::CaloVertexedTopoCluster cluster,
float &  out 
)

Definition at line 710 of file TauGNNUtils.cxx.

710  {
711  double double_out;
712  const auto success = cluster.clust().retrieveMoment(MomentType::SECOND_R, double_out);
713  out = static_cast<float>(double_out);
714  return success;
715 }
TauGNNUtils::Variables::Cluster::e
bool e(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:778
TauGNNUtils::Variables::Scalar::ClustersMeanSecondLambda
bool ClustersMeanSecondLambda(const xAOD::TauJet &tau, float &out)
Definition: TauGNNUtils.cxx:331
xAOD::CaloVertexedClusterBase::p4
virtual FourMom_t p4() const final
The full 4-momentum of the particle.
Definition: Event/xAOD/xAODCaloEvent/xAODCaloEvent/CaloVertexedClusterBase.h:88
xAOD::TauJet_v3::eta
virtual double eta() const
The pseudorapidity ( ) of the particle.
max
constexpr double max()
Definition: ap_fixedTest.cxx:33
min
constexpr double min()
Definition: ap_fixedTest.cxx:26
python.AthDsoLogger.out
out
Definition: AthDsoLogger.py:70
xAOD::CaloVertexedClusterBase::eta
virtual double eta() const final
The pseudorapidity ( ) of the particle.
Definition: Event/xAOD/xAODCaloEvent/xAODCaloEvent/CaloVertexedClusterBase.h:77
SG::ConstAccessor< float >
xAOD::CaloVertexedClusterBase::clust
const CaloCluster & clust() const
Return the cluster being proxied,.
Definition: Event/xAOD/xAODCaloEvent/xAODCaloEvent/CaloVertexedClusterBase.h:69
xAOD::TauJet_v3::ptJetSeed
double ptJetSeed() const
xAOD::TauJet_v3::pt
virtual double pt() const
The transverse momentum ( ) of the particle.
TauGNNUtils::Variables::Cluster::SECOND_LAMBDA
bool SECOND_LAMBDA(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:717
TauGNNUtils::Variables::Cluster::CENTER_MAG
bool CENTER_MAG(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:802
hist_file_dump.f
f
Definition: hist_file_dump.py:140
xAOD::CaloCluster_v1::retrieveMoment
bool retrieveMoment(MomentType type, double &value) const
Retrieve individual moment.
Definition: CaloCluster_v1.cxx:692
TauGNNUtils::Variables::Cluster::EM_PROBABILITY
bool EM_PROBABILITY(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:795
TauGNNUtils::Variables::Cluster::SECOND_R
bool SECOND_R(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:710
TauGNNUtils::Variables::Scalar::ClustersMeanCenterLambda
bool ClustersMeanCenterLambda(const xAOD::TauJet &tau, float &out)
Definition: TauGNNUtils.cxx:303
TauGNNUtils::Variables::Cluster::FIRST_ENG_DENS
bool FIRST_ENG_DENS(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:788
xAOD::TauJet_v3::p4
virtual FourMom_t p4() const
The full 4-momentum of the particle.
Definition: TauJet_v3.cxx:96
merge.status
status
Definition: merge.py:16
TauGNNUtils::Variables::Cluster::CENTER_LAMBDA
bool CENTER_LAMBDA(const xAOD::TauJet &, const xAOD::CaloVertexedTopoCluster &cluster, float &out)
Definition: TauGNNUtils.cxx:724