23 const IInterface* p) :
47 return StatusCode::SUCCESS;
57 ATH_CHECK(pairContainer.
record(std::make_unique<xAOD::VertexContainer>(), std::make_unique<xAOD::VertexAuxContainer>()));
59 ATH_CHECK(quadContainer.
record(std::make_unique<xAOD::VertexContainer>(), std::make_unique<xAOD::VertexAuxContainer>()));
60 bool acceptEvent =
false;
64 if( !
m_fourMuonTool->performSearch(pairContainer.
ptr(), quadContainer.
ptr(), acceptEvent, ctx).isSuccess() ) {
66 return StatusCode::FAILURE;
81 ATH_CHECK(refPvContainer.
record(std::make_unique<xAOD::VertexContainer>(), std::make_unique<xAOD::VertexAuxContainer>()));
87 if (quadContainer->size() >0) {
89 ATH_MSG_FATAL(
"refitting failed - check the vertices you passed");
90 return StatusCode::FAILURE;
93 if (pairContainer->size()>0) {
95 ATH_MSG_FATAL(
"refitting failed - check the vertices you passed");
96 return StatusCode::FAILURE;
100 if (quadContainer->size() >0) {
104 if (pairContainer->size() >0) {
134 double massErr =
m_v0Tools->invariantMassError(pairHelper.
vtx(), muonPairMasses);
159 double massErr =
m_v0Tools->invariantMassError(quadHelper.
vtx(), muonQuadMasses);
172 return StatusCode::SUCCESS;
193 const float errConst = -9999999;
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
#define BPHYS_CHECK(EXP)
Useful CHECK macro.
: B-physics xAOD helpers.
Helper class to provide constant type-safe access to aux data.
A number of constexpr particle constants to avoid hardcoding them directly in various places.
virtual StatusCode addBranches(const EventContext &ctx) const override final
ToolHandle< DerivationFramework::FourMuonTool > m_fourMuonTool
Gaudi::Property< bool > m_refitPV
ToolHandle< Analysis::PrimaryVertexRefitter > m_pvRefitter
Reco_4mu(const std::string &t, const std::string &n, const IInterface *p)
SG::WriteHandleKey< xAOD::VertexContainer > m_pairName
job options
PublicToolHandle< Trk::V0Tools > m_v0Tools
SG::ReadHandleKey< xAOD::VertexContainer > m_pvContainerName
Gaudi::Property< int > m_PV_max
SG::WriteHandleKey< xAOD::VertexContainer > m_refPVContainerName
Gaudi::Property< int > m_DoVertexType
virtual StatusCode initialize() override final
void ProcessVertex(xAOD::BPhysHypoHelper &, xAOD::BPhysHelper::pv_type, std::vector< double > trackMasses) const
tools
SG::WriteHandleKey< xAOD::VertexContainer > m_quadName
Helper class to provide constant type-safe access to aux data.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
const_pointer_type cptr()
Dereference the pointer.
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
pointer_type ptr()
Dereference the pointer.
const xAOD::Vertex * vtx() const
Getter method for the cached xAOD::Vertex.
const xAOD::Vertex * pv(const pv_type vertexType=BPhysHelper::PV_MIN_A0)
Get the refitted collision vertex of type pv_type.
pv_type
: Enum type of the PV
float mass() const
Get invariant mass and its error.
bool setMass(const float val)
Set given invariant mass and its error.
float massErr() const
invariant mass error
bool setTau(const float val, const pv_type vertexType=BPhysHelper::PV_MIN_A0, const tau_type tauType=BPhysHypoHelper::TAU_CONST_MASS)
: Set the proper decay time and error.
bool setMassErr(const float val)
invariant mass error
bool setTauErr(const float val, const pv_type vertexType=BPhysHelper::PV_MIN_A0, const tau_type tauType=BPhysHypoHelper::TAU_CONST_MASS)
proper decay time error
constexpr double muonMassInMeV
the mass of the muon (in MeV)
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Vertex_v1 Vertex
Define the latest version of the vertex class.