11#include "GaudiKernel/ToolHandle.h"
14#include "Rivet/AnalysisHandler.hh"
35 Rivet_i(
const std::string &name, ISvcLocator *pSvcLocator);
44 virtual StatusCode
execute()
override;
48 virtual StatusCode
finalize()
override;
60 std::unique_ptr<HepMC::GenEvent>
checkEvent(
const HepMC::GenEvent& event,
const EventContext& ctx);
63 void MeV2GeV(HepMC::GenEvent& event);
145 ,
"ReadHandleKey for xAOD::EventInfo" };
Define macros for attributes used to control the static checker.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
bool m_skipweights
Skip variation weights and only run nominal.
double m_weightcap
Weight cap to set allowed maximum for weights.
std::vector< std::string > m_analysisNames
A list of names of the analyses to run (set from the job properties)
bool m_ignorebeams
Whether to avoid the beam consistency checks.
double m_crossSection
The cross section for this run of events, set from the job properties.
bool m_patchBeams
Flag to insert beam protons when they are unavailable in the event.
virtual StatusCode finalize() override
Finalise each analysis and commit the plots to an AIDA tree and the THistSvc ROOT tree.
std::string m_anapath
The analysis plugin search path.
bool m_init
Flag to determine whether Rivet init has already happened (in execute())
ToolHandle< IxAODtoHepMCTool > m_xAODtoHepMCTool
A tool to convert xAOD::Truth to HepMC::GenEvent.
std::string m_file
The base file name to write results to.
std::string m_unmatchWeights
String of weight names (or regex) to veto multiweights.
std::string m_matchWeights
String of weight names (or regex) to select multiweights.
virtual StatusCode execute() override
Run the Rivet analyses on one event, which is retrieved from StoreGate.
SG::ReadHandleKey< xAOD::EventInfo > m_evtInfoKey
double m_crossSection_uncert
The uncertainity of the cross section for this run of events, set from the job properties.
bool m_needsConversion
Do we need to convert xAOD::Truth back to HepMC::GenEvemt?
Rivet::AnalysisHandler * m_analysisHandler
A Rivet analysis handler.
bool m_doRootHistos
Will we convert Rivet's internal histo format into a ROOT histo for streaming with THistSvc?
std::string m_stream
A pointer to the THistSvc.
Rivet_i(const std::string &name, ISvcLocator *pSvcLocator)
Standard algorithm constructor.
std::unique_ptr< HepMC::GenEvent > checkEvent(const HepMC::GenEvent &event, const EventContext &ctx)
Book an AIDA::IDataPointSet into the THistSvc as a TH1D at path.
std::string m_genEventKey
The GenEvent StoreGate key (default "GEN_EVENT")
std::string m_nominalWeightName
String to specify non-standard nominal weight.
void MeV2GeV(HepMC::GenEvent &event)
virtual StatusCode initialize ATLAS_NOT_THREAD_SAFE() override
Initialise the Rivet interface and Athena services.
std::string m_runname
The name of the run (prepended to plot paths).
Property holding a SG store/key/clid from which a ReadHandle is made.