ATLAS Offline Software
Loading...
Searching...
No Matches
GlobalSim::LArStripNeighborhoodDumper Class Reference

#include <LArStripNeighborhoodDumper.h>

Collaboration diagram for GlobalSim::LArStripNeighborhoodDumper:

Public Member Functions

 LArStripNeighborhoodDumper ()
StatusCode dump (const std::string &name, const xAOD::EventInfo &eventInfo, const IOBitwise::eEmNbhoodTOBContainer &) const
StatusCode dumpTerse (const std::string &name, const xAOD::EventInfo &eventInfo, const IOBitwise::eEmNbhoodTOBContainer &) const

Detailed Description

Definition at line 14 of file LArStripNeighborhoodDumper.h.

Constructor & Destructor Documentation

◆ LArStripNeighborhoodDumper()

GlobalSim::LArStripNeighborhoodDumper::LArStripNeighborhoodDumper ( )

Definition at line 10 of file LArStripNeighborhoodDumper.cxx.

10 {
11 }

Member Function Documentation

◆ dump()

StatusCode GlobalSim::LArStripNeighborhoodDumper::dump ( const std::string & name,
const xAOD::EventInfo & eventInfo,
const IOBitwise::eEmNbhoodTOBContainer & neighborhoodTOBs ) const

Definition at line 14 of file LArStripNeighborhoodDumper.cxx.

16 {
17
18 std::ofstream out(name + "_" +
19 std::to_string(eventInfo.eventNumber()) +
20 ".log");
21
22 out << "run " << eventInfo.runNumber()
23 << " evt " << eventInfo.eventNumber()
24 << " is simulation " << std::boolalpha
26 << " weight " << eventInfo.mcEventWeight() << '\n';
27
28 for (const auto nbhdTOB : neighborhoodTOBs) {
29 out << nbhdTOB->Neighbourhood() << '\n';
30 }
31
32 out.close();
33
34 return StatusCode::SUCCESS;
35 }
bool eventType(EventType type) const
Check for one particular bitmask value.
@ IS_SIMULATION
true: simulation, false: data
uint32_t runNumber() const
The current event's run number.
uint64_t eventNumber() const
The current event's event number.
float mcEventWeight(size_t i=0) const
The weight of one specific MC event used in the simulation.

◆ dumpTerse()

StatusCode GlobalSim::LArStripNeighborhoodDumper::dumpTerse ( const std::string & name,
const xAOD::EventInfo & eventInfo,
const IOBitwise::eEmNbhoodTOBContainer & neighborhoodTOBs ) const

Definition at line 65 of file LArStripNeighborhoodDumper.cxx.

67 {
68
69 std::ofstream out(name + "_" +
70 std::to_string(eventInfo.eventNumber()) +
71 "_terse.log");
72 out << "run " << eventInfo.runNumber()
73 << " evt " << eventInfo.eventNumber()
74 << " is simulation " << std::boolalpha
76 << " weight " << eventInfo.mcEventWeight() << '\n';
77
78 for (const auto nTOB : neighborhoodTOBs) {dump_n(nTOB->Neighbourhood(), out);}
79
80
81 out.close();
82
83 return StatusCode::SUCCESS;
84 }
void dump_n(const LArStripNeighborhood &n, std::ostream &os)

The documentation for this class was generated from the following files: