Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set global RAT-PAC2 compile flag to -Wall -Werror #200

Merged
merged 8 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from 2 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
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
"Debug" "Release" "MinSizeRel" "RelWithDebInfo")
endif()
add_compile_options(-Wno-terminate)
add_compile_options(-Wall -Werror)

###########################################################
# Set CMAKE standards
Expand Down
2 changes: 1 addition & 1 deletion src/core/include/RAT/Log.hh
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ class Log {

/** Write @p message to @p warn stream and immediately terminate,
sending @p return_code back to OS. */
static void Die(std::string message, int return_code = 1);
[[noreturn]] static void Die(std::string message, int return_code = 1);

/** Write @p message to @p warn stream and immediately terminate if @condition
is not true. @p return_code is returned to the OS to signal job failure
Expand Down
12 changes: 6 additions & 6 deletions src/daq/include/RAT/WaveformAnalysis.hh
Original file line number Diff line number Diff line change
Expand Up @@ -92,14 +92,14 @@ class WaveformAnalysis : public Processor {
double fTermOhms;

// Analysis constants
int fPedWindowLow;
int fPedWindowHigh;
size_t fPedWindowLow;
size_t fPedWindowHigh;
double fLookback;
int fIntWindowLow;
int fIntWindowHigh;
size_t fIntWindowLow;
size_t fIntWindowHigh;
double fConstFrac;
int fLowIntWindow;
int fHighIntWindow;
size_t fLowIntWindow;
size_t fHighIntWindow;
double fVoltageCrossing;
double fThreshold;
int fSlidingWindow;
Expand Down
2 changes: 1 addition & 1 deletion src/daq/src/AfterPulseProc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ double AfterPulseProc::CalculateAfterPulseTime(double apFraction, std::vector<do
std::vector<double> apProb) {
const double randtime = G4UniformRand();
size_t up = 1;
for (int i = 1; i < apTime.size(); i++) {
for (size_t i = 1; i < apTime.size(); i++) {
if (randtime < apProb[i]) {
up = i;
i = apTime.size();
Expand Down
2 changes: 1 addition & 1 deletion src/daq/src/NoiseProc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ int NoiseProc::GenerateNoiseInWindow(DS::MC *mc, double noiseBegin, double noise
// the pmts are indistinguishable then we can take a shortcut and generate
// the total count first and speed things along.
double noiseWindowWidth = noiseEnd - noiseBegin;
size_t pmtCount = pmtinfo->GetPMTCount();
int pmtCount = pmtinfo->GetPMTCount();
int noiseHits = 0;

if (fNoiseFlag == 0) {
Expand Down
4 changes: 2 additions & 2 deletions src/daq/src/PMTPulse.cc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ double PMTPulse::GetDataDrivenPulseVal(double time) {
// pulse not defined for this value
return 0.;
}
int i = 0;
size_t i = 0;
for (i = 0; i < fPulseTimes.size() - 1; i++) {
if (time > fPulseTimes[i]) {
continue;
Expand Down Expand Up @@ -62,4 +62,4 @@ double PMTPulse::GetPulseHeight(double utime) {
return height;
}

} // namespace RAT
} // namespace RAT
2 changes: 1 addition & 1 deletion src/daq/src/WaveformAnalysis.cc
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ void WaveformAnalysis::Integrate() {
// Make sure not to integrate before the waveform starts
fLowIntWindow = (fLowIntWindow < 0) ? 0 : fLowIntWindow;

for (int i = fLowIntWindow; i < fHighIntWindow; i++) {
for (size_t i = fLowIntWindow; i < fHighIntWindow; i++) {
double voltage = DigitToVoltage(fDigitWfm[i]);
fCharge += (-voltage * fTimeStep) / fTermOhms; // in pC
}
Expand Down
1 change: 0 additions & 1 deletion src/daq/src/WaveformAnalyzerBase.cc
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ Processor::Result WaveformAnalyzerBase::Event(DS::Root* ds, DS::EV* ev) {
return Processor::Result::OK;
}
DS::Digit* dsdigit = &ev->GetDigitizer();
DS::Run* run = DS::RunStore::GetRun(ds->GetRunID());
std::vector<int> pmt_ids = ev->GetAllDigitPMTIDs();
for (int pmt_id : pmt_ids) {
DS::DigitPMT* digitpmt = ev->GetOrCreateDigitPMT(pmt_id);
Expand Down
4 changes: 0 additions & 4 deletions src/daq/src/WaveformPrep.cc
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,6 @@ double WaveformPrep::RunAnalysisOnTrigger(int pmtID, Digitizer* fDigitizer) {
// Convert from ADC to mV
std::vector<double> voltWfm = WaveformUtil::ADCtoVoltage(digitWfm, fVoltageRes);

// Calculate baseline in mV
double pedestal = WaveformUtil::CalculatePedestalmV(voltWfm, fPedWindowLow, fPedWindowHigh);

double trigger_threshold = fThreshold;
double trigger_lookback = fLookback;
try {
Expand All @@ -167,7 +164,6 @@ double WaveformPrep::RunAnalysisOnTrigger(int pmtID, Digitizer* fDigitizer) {
// Calculate highest peak in mV
std::pair<int, double> peak = WaveformUtil::FindHighestPeak(voltWfm);
int samplePeak = peak.first;
double voltagePeak = peak.second;
// HACK: Store the old lookback value, restore after a trigger time analysis is done.
double old_lookback = fLookback;
fLookback = trigger_lookback;
Expand Down
4 changes: 2 additions & 2 deletions src/ds/include/RAT/DS/Classifier.hh
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ namespace DS {

class Classifier : public TObject {
public:
Classifier() : TObject(), classifier_name(""), classificationLabels(std::vector<std::string>{""}) {
Classifier() : TObject(), classificationLabels(std::vector<std::string>{""}), classifier_name("") {
int index = 0;
for (auto &L : classificationLabels) {
this->nameIndexMap[L] = index++;
this->classificationResults.push_back(0.0);
}
}
Classifier(std::string name, std::vector<std::string> labels)
: TObject(), classifier_name(name), classificationLabels(labels) {
: TObject(), classificationLabels(labels), classifier_name(name) {
int index = 0;
for (auto &L : labels) {
this->nameIndexMap[L] = index++;
Expand Down
2 changes: 1 addition & 1 deletion src/ds/src/MCPMT.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace DS {
std::string MCPMT::GetCreatorProcess() const {
std::string process = "";
double time = 9999.;
for (int iph = 0; iph < photon.size(); iph++) {
for (size_t iph = 0; iph < photon.size(); iph++) {
if (photon[iph].GetFrontEndTime() < time) {
time = photon[iph].GetFrontEndTime();
process = photon[iph].GetCreatorProcess();
Expand Down
4 changes: 2 additions & 2 deletions src/gen/src/GLG4PosGen.cc
Original file line number Diff line number Diff line change
Expand Up @@ -544,8 +544,8 @@ void GLG4PosGen_FillCyl::GeneratePosition(G4ThreeVector &argResult) {
double theVolume = theSolid->GetCubicVolume(); // in cubic meters
double theMass = theLogVolume->GetMass(false, false);
double theNelec = theMaterial->GetElectronDensity();
// RAT::info << "[GLG4PosGen_FillCyl] Volume " << theVolume << " " << theMass
// << newline; RAT::info << "[GLG4PosGen_FillCyl] Nelec " << theNelec << newline;
RAT::debug << "[GLG4PosGen_FillCyl] Volume " << theVolume << " " << theMass << newline;
RAT::info << "[GLG4PosGen_FillCyl] Nelec " << theNelec << newline;
JamesJieranShen marked this conversation as resolved.
Show resolved Hide resolved
}
return;
}
Expand Down
2 changes: 1 addition & 1 deletion src/gen/src/Gen_LED.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Gen_LED::~Gen_LED() {
}

void Gen_LED::GenerateEvent(G4Event *event) {
if (selectedLED >= 0 && selectedLED < led_x.size()) {
if (selectedLED >= 0 && static_cast<size_t>(selectedLED) < led_x.size()) {
next_led = selectedLED;
}
// Get information on next LED to fire
Expand Down
6 changes: 3 additions & 3 deletions src/gen/src/HeGen.cc
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ HeGen::HeGen() : stateStr(""), isotope(8), posGen(0) {
// cdf (cumulativ distribution fnction) for branching ratio
pdfNow = 0.;
sumBr = accumulate(std::begin(brArrHe), std::end(brArrHe), 0., std::plus<double>());
for (int j = 0; j < sizeof(brArrHe) / sizeof(brArrHe[0]); j++) {
for (size_t j = 0; j < sizeof(brArrHe) / sizeof(brArrHe[0]); j++) {
pdfNow += brArrHe[j] / sumBr;
cdfHe[j] = pdfNow;
}
Expand Down Expand Up @@ -112,9 +112,9 @@ void HeGen::GenerateEvent(G4Event *event) {

// energy
// energy
int idxNow = 0;
size_t idxNow = 0;
G4double randNow = G4UniformRand();
for (int j = 0; j < sizeof(brArrHe) / sizeof(brArrHe[0]); j++) {
for (size_t j = 0; j < sizeof(brArrHe) / sizeof(brArrHe[0]); j++) {
if (randNow < cdfHe[j]) {
idxNow = j;
break;
Expand Down
7 changes: 4 additions & 3 deletions src/gen/src/LiGen.cc
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include <RAT/LiGen.hh>
#include <RAT/Log.hh>
#include <Randomize.hh>
#include <cstddef>
#include <numeric>
#include <string>

Expand Down Expand Up @@ -72,7 +73,7 @@ LiGen::LiGen() : stateStr(""), isotope(9), posGen(0) {
// cdf (cumulativ distribution fnction) for branching ratio
pdfNow = 0.;
sumBr = accumulate(std::begin(brArrLi), std::end(brArrLi), 0., std::plus<double>());
for (int j = 0; j < sizeof(brArrLi) / sizeof(brArrLi[0]); j++) {
for (size_t j = 0; j < sizeof(brArrLi) / sizeof(brArrLi[0]); j++) {
pdfNow += brArrLi[j] / sumBr;
cdfLi[j] = pdfNow;
}
Expand Down Expand Up @@ -111,9 +112,9 @@ void LiGen::GenerateEvent(G4Event *event) {
G4double pz = cost;

// energy
int idxNow = 0;
size_t idxNow = 0;
G4double randNow = G4UniformRand();
for (int j = 0; j < sizeof(brArrLi) / sizeof(brArrLi[0]); j++) {
for (size_t j = 0; j < sizeof(brArrLi) / sizeof(brArrLi[0]); j++) {
if (randNow < cdfLi[j]) {
idxNow = j;
break;
Expand Down
6 changes: 3 additions & 3 deletions src/gen/src/NGen.cc
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ NGen::NGen() : stateStr(""), isotope(17), posGen(0) {
// cdf (cumulativ distribution fnction) for branching ratio
pdfNow = 0.;
sumBr = accumulate(std::begin(brArrN), std::end(brArrN), 0., std::plus<double>());
for (int j = 0; j < sizeof(brArrN) / sizeof(brArrN[0]); j++) {
for (size_t j = 0; j < sizeof(brArrN) / sizeof(brArrN[0]); j++) {
pdfNow += brArrN[j] / sumBr;
cdfN[j] = pdfNow;
}
Expand Down Expand Up @@ -109,9 +109,9 @@ void NGen::GenerateEvent(G4Event *event) {
G4double pz = cost;

// energy
int idxNow = 0;
size_t idxNow = 0;
G4double randNow = G4UniformRand();
for (int j = 0; j < sizeof(brArrN) / sizeof(brArrN[0]); j++) {
for (size_t j = 0; j < sizeof(brArrN) / sizeof(brArrN[0]); j++) {
if (randNow < cdfN[j]) {
idxNow = j;
break;
Expand Down
4 changes: 2 additions & 2 deletions src/gen/src/PosGen_RegexFill.cc
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ void PosGen_RegexFill::SetState(G4String regex) {
}

void PosGen_RegexFill::FindVolumes(G4LogicalVolume *mother, regex_t *re, std::vector<FillVolume> &found) {
for (int i = 0; i < mother->GetNoDaughters(); i++) {
for (size_t i = 0; i < mother->GetNoDaughters(); i++) {
G4VPhysicalVolume *daughterPhys = mother->GetDaughter(i);
G4LogicalVolume *daughterLog = daughterPhys->GetLogicalVolume();
// this projects from daughter to mother coordinates
Expand All @@ -61,7 +61,7 @@ void PosGen_RegexFill::FindVolumes(G4LogicalVolume *mother, regex_t *re, std::ve
G4VSolid *solid = daughterLog->GetSolid();
// volume of parent+daughters needs to be corrected
vol.solidVolume = GetVolume(solid);
for (int j = 0; j < daughterLog->GetNoDaughters(); j++) {
for (size_t j = 0; j < daughterLog->GetNoDaughters(); j++) {
G4VPhysicalVolume *grandPhys = daughterLog->GetDaughter(j);
G4AffineTransform grandTransform(grandPhys->GetRotation(), grandPhys->GetTranslation());
G4VSolid *grandSolid = grandPhys->GetLogicalVolume()->GetSolid();
Expand Down
6 changes: 2 additions & 4 deletions src/gen/src/SNgen.cc
Original file line number Diff line number Diff line change
Expand Up @@ -375,8 +375,7 @@ double SNgen::GetESRandomEnergy(Double_t &dt) {
ES_e_Flux->Delete();
ES_e_XS->Delete();
ES_e_Total->Delete();
}
if (0.167 < ran_ES && ran_ES <= 0.33) {
} else if (ran_ES <= 0.33) {
Double_t ran_ES_eb = glum_eb->GetRandom();
dt = ran_ES_eb;
Double_t meran_ES_eb = gmene_eb->Eval(ran_ES_eb);
Expand All @@ -401,8 +400,7 @@ double SNgen::GetESRandomEnergy(Double_t &dt) {
ES_eb_Flux->Delete();
ES_eb_XS->Delete();
ES_eb_Total->Delete();
}
if (ran_ES > 0.33) {
} else {
Double_t ran_ES_x = glum_x->GetRandom();
dt = ran_ES_x;
Double_t meran_ES_x = gmene_x->Eval(ran_ES_x);
Expand Down
2 changes: 1 addition & 1 deletion src/gen/src/VertexGen_CRY.cc
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ VertexGen_CRY::VertexGen_CRY(const char *arg_dbname) : GLG4VertexGen(arg_dbname)
startTime.Set(year, month, day, 0, 0, 0, 0, 1, 0);
}
void VertexGen_CRY::GeneratePrimaryVertex(G4Event *event, G4ThreeVector &dx, G4double dt) {
int nParticles = 0;
// int nParticles = 0;
JamesJieranShen marked this conversation as resolved.
Show resolved Hide resolved
std::vector<CRYParticle *> *cryvector = new std::vector<CRYParticle *>;
// Now the interesting bit
generator->genEvent(cryvector);
Expand Down
2 changes: 0 additions & 2 deletions src/gen/src/VertexGen_FastNeutron.cc
Original file line number Diff line number Diff line change
Expand Up @@ -282,8 +282,6 @@ double VertexGen_FastNeutron::evalIntegral(TF2 *func1, double x, double e_tmp) {
Double_t logxmin = log10(e_tmp);
Double_t logxmax = 8.0;
Double_t binwidth = (logxmax - logxmin) / double(nbins);
Double_t xbins[nbins];
xbins[0] = e_tmp;
Double_t norm = log(10) * binwidth;
Double_t tmp = 0.0, a = 0.0;
for (int i = 0.0; i < nbins; i++) {
Expand Down
2 changes: 1 addition & 1 deletion src/geo/src/BWVetGenericChamber.cc
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ G4bool BWVetGenericChamber::ProcessHits(G4Step *aStep, G4TouchableHistory * /*RO
}

if (_hitsCollection) {
for (G4int i = 0; i < _hitsCollection->entries(); i++) {
for (size_t i = 0; i < _hitsCollection->entries(); i++) {
// RAT::debug << " * BWVetGenericChamber::ProcessHits checking hit "
// << i + 1
// << " of "
Expand Down
23 changes: 10 additions & 13 deletions src/geo/src/GeoCalibrationStickFactory.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ G4VPhysicalVolume *GeoCalibrationStickFactory::Construct(DBLinkPtr table) {

G4ThreeVector offset(positionArray[0], positionArray[1], positionArray[2]);

const double sourceCenter = stickLength / 2.0 - sourceThickness / 2.0;

// Main outer tube
G4Material *stickMaterial = G4Material::GetMaterial(table->GetS("stick_material"));
// const std::vector<double> &sourceColor = table->GetDArray("source_vis_color");
Expand Down Expand Up @@ -70,23 +68,22 @@ G4VPhysicalVolume *GeoCalibrationStickFactory::Construct(DBLinkPtr table) {

// Put stuff in the mother volume
G4VPhysicalVolume *motherPhys = FindPhysMother(motherName);
G4LogicalVolume *motherLog = FindMother(motherName);

G4RotationMatrix *rotation = motherPhys->GetObjectRotation();
G4ThreeVector position = motherPhys->GetObjectTranslation();
// second is rotation, first is position
position = position + G4ThreeVector(0.0, 0.0, stickLength / 2.0 + bottomThickness) + offset;

G4VPhysicalVolume *stickPhys =
new G4PVPlacement(rotation, position, "CalibrationStick_Stick", stickLog, motherPhys, false, 0);
G4VPhysicalVolume *bottomPhys =
new G4PVPlacement(rotation, position - G4ThreeVector(0, 0, (stickLength + bottomThickness) / 2.0),
"CalibrationStick_Bottom", bottomLog, motherPhys, false, 0);
G4VPhysicalVolume *gasPhys =
new G4PVPlacement(rotation, position, "CalibrationStick_Gas", gasLog, motherPhys, false, 0);
G4VPhysicalVolume *sourcePhys =
new G4PVPlacement(rotation, position - G4ThreeVector(0, 0, (stickLength / 2.0) - sourcePosition),
"CalibrationStick_Source", sourceLog, motherPhys, false, 0);
// G4VPhysicalVolume *stickPhys =
new G4PVPlacement(rotation, position, "CalibrationStick_Stick", stickLog, motherPhys, false, 0);
// G4VPhysicalVolume *bottomPhys =
new G4PVPlacement(rotation, position - G4ThreeVector(0, 0, (stickLength + bottomThickness) / 2.0),
"CalibrationStick_Bottom", bottomLog, motherPhys, false, 0);
// G4VPhysicalVolume *gasPhys =
new G4PVPlacement(rotation, position, "CalibrationStick_Gas", gasLog, motherPhys, false, 0);
// G4VPhysicalVolume *sourcePhys =
new G4PVPlacement(rotation, position - G4ThreeVector(0, 0, (stickLength / 2.0) - sourcePosition),
"CalibrationStick_Source", sourceLog, motherPhys, false, 0);

// Set visuals
SetVis(stickLog, table->GetDArray("stick_color"));
Expand Down
4 changes: 2 additions & 2 deletions src/geo/src/GeoCherenkovSourceFactory.cc
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ G4VPhysicalVolume *GeoCherenkovSourceFactory::Construct(DBLinkPtr table) {
const std::vector<double> &pmtColor = table->GetDArray("pmt_vis_color");
const double pmtRadius = table->GetD("pmt_radius");
const double pmtHeight = table->GetD("pmt_height");
const int pmtLcn = table->GetI("pmt_lcn");
// const int pmtLcn = table->GetI("pmt_lcn");

// Calculate the z location of the start of the neck
double neckStartZ = sqrt(ballId * ballId / 4.0 - neckId * neckId / 4.0);
Expand Down Expand Up @@ -322,7 +322,7 @@ G4VPhysicalVolume *GeoCherenkovSourceFactory::Construct(DBLinkPtr table) {

// Put stuff in the mother volume
G4VPhysicalVolume *motherPhys = FindPhysMother(table->GetS("mother"));
G4LogicalVolume *motherLog = FindMother(table->GetS("mother"));
// G4LogicalVolume *motherLog = FindMother(table->GetS("mother"));
// G4VPhysicalVolume *canPhys = ConstructPhysicalVolume(canLog, motherLog,
// table);

Expand Down
8 changes: 4 additions & 4 deletions src/geo/src/Materials.cc
Original file line number Diff line number Diff line change
Expand Up @@ -634,10 +634,10 @@ void Materials::LoadOptics() {
// scattering, which is combined into a single scattering length
mpt->AddConstProperty("NCOMPONENTS", components.size(), true);

const std::vector<G4MaterialPropertyVector *> &materialPropertyVector = mpt->GetProperties();
// const std::vector<G4MaterialPropertyVector *> &materialPropertyVector = mpt->GetProperties();
const std::vector<G4String> &materialPropertyNames = mpt->GetMaterialPropertyNames();
const std::vector<G4String> &materialConstPropertyNames = mpt->GetMaterialConstPropertyNames();
const std::vector<std::pair<G4double, G4bool>> &materialConstPropertyVector = mpt->GetConstProperties();
// const std::vector<std::pair<G4double, G4bool>> &materialConstPropertyVector = mpt->GetConstProperties();

for (size_t i = 0; i < components.size(); i++) {
std::string compname = components[i];
Expand Down Expand Up @@ -669,7 +669,7 @@ void Materials::LoadOptics() {
/// G4MaterialPropertyVector*>::const_iterator it;
auto cptPropertyNames = cpt->GetMaterialPropertyNames();
auto cptProperties = cpt->GetProperties();
for (int propid = 0; propid < cptPropertyNames.size(); propid++) {
for (size_t propid = 0; propid < cptPropertyNames.size(); propid++) {
//// for (it=cpm->begin(); it!=cpm->end(); it++) {
//// std::string pname = it->first;
G4String pname = cptPropertyNames.at(propid);
Expand Down Expand Up @@ -747,7 +747,7 @@ void Materials::LoadOptics() {
//// std::map<G4String,
//// G4double>::const_iterator itc;
//// for (itc=cpmc->begin(); itc!=cpmc->end(); itc++) {
for (int propid = 0; propid < cptConstPropertyNames.size(); propid++) {
for (size_t propid = 0; propid < cptConstPropertyNames.size(); propid++) {
G4String cname = cptConstPropertyNames.at(propid);
//// std::string cname = itc->first;
if (cname.find("REEMISSION_PROB") != std::string::npos) {
Expand Down
2 changes: 0 additions & 2 deletions src/io/src/OutNtupleProc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ OutNtupleProc::OutNtupleProc() : Processor("outntuple") {
}

bool OutNtupleProc::OpenFile(std::string filename) {
int i = 0;
outputFile = TFile::Open(filename.c_str(), "RECREATE");
// Meta Tree
metaTree = new TTree("meta", "meta");
Expand Down Expand Up @@ -213,7 +212,6 @@ Processor::Result OutNtupleProc::DSEvent(DS::Root *ds) {
runBranch = DS::RunStore::GetRun(ds);
DS::PMTInfo *pmtinfo = runBranch->GetPMTInfo();
const DS::ChannelStatus *channel_status = runBranch->GetChannelStatus();
ULong64_t stonano = 1000000000;
dsentries++;
// Clear the previous vectors
pdgcodes.clear();
Expand Down
Loading