Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions sbnanaobj/StandardRecord/SREXTInfo.cxx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#include "sbnanaobj/StandardRecord/SREXTInfo.h"

#include <limits>
#include <climits>

namespace caf
{
SREXTInfo::SREXTInfo():
gates_since_last_trigger(std::numeric_limits<unsigned int>::max()),
isBNBOffBeam(false),
isNuMIOffBeam(false),
isMajority(false),
isMinBias(false)
Comment on lines +12 to +13

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should be commented what they mean or their name should be changed to something more generic.

{}
}
18 changes: 18 additions & 0 deletions sbnanaobj/StandardRecord/SREXTInfo.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#ifndef SREXTInfo_h
#define SREXTInfo_h

namespace caf
{
class SREXTInfo
{
public:
SREXTInfo();
unsigned int gates_since_last_trigger;
bool isBNBOffBeam;
bool isNuMIOffBeam;
bool isMajority;
bool isMinBias;
Comment on lines +13 to +14

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These should be commented what they mean or their name should be changed to something more generic.

};
}

#endif
1 change: 1 addition & 0 deletions sbnanaobj/StandardRecord/SRHeader.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ namespace caf
// blind(false),
nbnbinfo(0),
nnumiinfo(0),
nextinfo(0),
ntriggerinfo(0),
husk(false)
{ }
Expand Down
4 changes: 4 additions & 0 deletions sbnanaobj/StandardRecord/SRHeader.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include "sbnanaobj/StandardRecord/SREnums.h"
#include "sbnanaobj/StandardRecord/SRBNBInfo.h"
#include "sbnanaobj/StandardRecord/SRNuMIInfo.h"
#include "sbnanaobj/StandardRecord/SREXTInfo.h"
#include "sbnanaobj/StandardRecord/SRTrigger.h"

#include <vector>
Expand All @@ -32,6 +33,7 @@ namespace caf
unsigned int fno; ///< Index of file processed by CAFMaker
unsigned int ngenevt; ///< Number of events generated in input file associated with this record (before any filters)
float pot; ///< POT of the subrun associated with this record
float extcount;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like the number of "beam gates" is missing, which would be needed to normalize "extcount" to "pot".

Also, it looks like "extcount" is missing a comment describing it.

MCType_t mctype; ///< Type of Monte Carlo used to generate this record
Det_t det; ///< Detector, SBND=1 ICARUS=2
bool first_in_subrun; ///< Whether this event is the first in the subrun
Expand All @@ -43,6 +45,8 @@ namespace caf
std::vector<caf::SRBNBInfo> bnbinfo; ///< storing beam information per subrun
size_t nnumiinfo; ///< Number of NuMIInfo objects
std::vector<caf::SRNuMIInfo> numiinfo; ///< storing beam information per subrun
size_t nextinfo;
std::vector<caf::SREXTInfo> extinfo;
size_t ntriggerinfo; ///< Number of Trigger objects
std::vector<caf::SRTrigger> triggerinfo; ///< storing trigger information per event

Expand Down
6 changes: 5 additions & 1 deletion sbnanaobj/StandardRecord/classes_def.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</class>

<class name="caf::SRHeader" ClassVersion="17">
<version ClassVersion="17" checksum="2390355049"/>
<version ClassVersion="17" checksum="2118058550"/>
<version ClassVersion="16" checksum="2130480854"/>
<version ClassVersion="15" checksum="2023063203"/>
<version ClassVersion="14" checksum="381900980"/>
Expand Down Expand Up @@ -234,6 +234,9 @@
<version ClassVersion="10" checksum="3796231674"/>
</class>

<class name="caf::SREXTInfo" ClassVersion="10">
<version ClassVersion="10" checksum="850665470"/>
</class>
<class name="caf::SRCRUMBSResult" ClassVersion="11">
<version ClassVersion="11" checksum="2106876613"/>
<version ClassVersion="10" checksum="783958853"/>
Expand Down Expand Up @@ -279,6 +282,7 @@
<class name="std::vector<caf::SRStubPlane>" />
<class name="std::vector<caf::SRBNBInfo>" />
<class name="std::vector<caf::SRNuMIInfo>" />
<class name="std::vector<caf::SREXTInfo>" />
<class name="std::vector<caf::SRCRUMBSResult>" />
<class name="std::vector<caf::SRTrigger>" />

Expand Down