#include <InvariantMassTool.h>
|
| std::string | m_expression |
| |
| std::string | m_expression2 |
| |
| SG::WriteHandleKey< std::vector< float > > | m_sgName {this,"StoreGateEntryName","","SG key of output object"} |
| |
| float | m_massHypothesis |
| |
| float | m_massHypothesis2 |
| |
| SG::ReadHandleKey< xAOD::IParticleContainer > | m_containerName {this,"ContainerName","","SG key of first container"} |
| |
| SG::ReadHandleKey< xAOD::IParticleContainer > | m_containerName2 {this,"SecondContainerName","","SG key of second container"} |
| |
| SG::ReadDecorHandleKeyArray< xAOD::IParticleContainer > | m_inputDecorNames {this, "InputDecorNames",{},"SG keys for decorations of first (and second) container(s)"} |
| |
Definition at line 30 of file InvariantMassTool.h.
◆ InvariantMassTool()
| DerivationFramework::InvariantMassTool::InvariantMassTool |
( |
const std::string & |
t, |
|
|
const std::string & |
n, |
|
|
const IInterface * |
p |
|
) |
| |
◆ addBranches()
| StatusCode DerivationFramework::InvariantMassTool::addBranches |
( |
const EventContext & |
ctx | ) |
const |
|
virtual |
Definition at line 59 of file InvariantMassTool.cxx.
63 ATH_MSG_ERROR(
"Tool is attempting to write a StoreGate key " <<
m_sgName <<
" which already exists. Please use a different key");
64 return StatusCode::FAILURE;
66 std::unique_ptr<std::vector<float> >
masses(
new std::vector<float>());
71 return StatusCode::SUCCESS;
◆ calculateInvariantMass()
| float DerivationFramework::InvariantMassTool::calculateInvariantMass |
( |
const TVector3 & |
v1, |
|
|
const TVector3 & |
v2, |
|
|
float |
M1, |
|
|
float |
M2 |
|
) |
| |
|
staticprivate |
Definition at line 160 of file InvariantMassTool.cxx.
161 TLorentzVector
p1(v1, M1 > 0 ? std::hypot(M1, v1.Mag()) : v1.Mag());
162 TLorentzVector
p2(
v2, M2 > 0 ? std::hypot(M2,
v2.Mag()) :
v2.Mag());
◆ finalize()
| StatusCode DerivationFramework::InvariantMassTool::finalize |
( |
| ) |
|
◆ getInvariantMasses()
| StatusCode DerivationFramework::InvariantMassTool::getInvariantMasses |
( |
std::vector< float > * |
masses, |
|
|
const EventContext & |
ctx |
|
) |
| const |
|
private |
Definition at line 74 of file InvariantMassTool.cxx.
81 return StatusCode::FAILURE;
86 bool from2Collections(
false);
90 particles2=particleHdl2.cptr();
91 from2Collections =
true;
98 unsigned int nEntries2 = entries2.size();
101 if (!from2Collections) {
103 ATH_MSG_ERROR(
"Branch sizes incompatible - returning zero. Check your selection strings.");
105 return StatusCode::FAILURE;
108 if (from2Collections) {
110 ATH_MSG_ERROR(
"Branch sizes incompatible - returning zero. Check your selection strings.");
112 return StatusCode::FAILURE;
117 unsigned int outerIt, innerIt;
118 std::vector<std::pair<int, int> >
pairs;
120 if (!from2Collections) {
121 for (outerIt=0; outerIt<
nEntries; ++outerIt) {
122 for (innerIt=outerIt+1; innerIt<
nEntries; ++innerIt) {
123 pairs.push_back({
static_cast<int>(outerIt),
static_cast<int>(innerIt)});
139 if (from2Collections) {
140 for (outerIt=0; outerIt<
nEntries; ++outerIt) {
141 if (
entries[outerIt]==0)
continue;
142 for (innerIt=0; innerIt<nEntries2; ++innerIt) {
143 if (entries2[innerIt]==0)
continue;
144 pairs.push_back({
static_cast<int>(outerIt),
static_cast<int>(innerIt)});
150 ((*particles2)[
second])->p4().Vect(),
157 return StatusCode::SUCCESS;
◆ initialize()
| StatusCode DerivationFramework::InvariantMassTool::initialize |
( |
| ) |
|
Definition at line 32 of file InvariantMassTool.cxx.
35 ATH_MSG_ERROR(
"No SG name provided for the output of invariant mass tool!");
36 return StatusCode::FAILURE;
50 return StatusCode::SUCCESS;
◆ m_containerName
◆ m_containerName2
◆ m_expression
| std::string DerivationFramework::InvariantMassTool::m_expression |
|
private |
◆ m_expression2
| std::string DerivationFramework::InvariantMassTool::m_expression2 |
|
private |
◆ m_inputDecorNames
◆ m_massHypothesis
| float DerivationFramework::InvariantMassTool::m_massHypothesis |
|
private |
◆ m_massHypothesis2
| float DerivationFramework::InvariantMassTool::m_massHypothesis2 |
|
private |
◆ m_sgName
| SG::WriteHandleKey<std::vector<float> > DerivationFramework::InvariantMassTool::m_sgName {this,"StoreGateEntryName","","SG key of output object"} |
|
private |
The documentation for this class was generated from the following files: