Skip to content

Commit aad2ae1

Browse files
authored
Merge branch 'develop' into feature/aheggest_RWMinCAF
2 parents 0f63559 + 45b7e0c commit aad2ae1

8 files changed

Lines changed: 47 additions & 14 deletions

File tree

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
cmake_minimum_required(VERSION 3.20 FATAL_ERROR)
1717

1818
find_package(cetmodules 3.20.00 REQUIRED)
19-
project(sbncode VERSION 10.06.00.01 LANGUAGES CXX)
19+
project(sbncode VERSION 10.06.00.04 LANGUAGES CXX)
2020

2121
message(STATUS "\n\n ========================== ${PROJECT_NAME} ==========================")
2222

sbncode/BeamSpillInfoRetriever/BNBEXTRetriever/BNBEXTRetriever_module.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ void sbn::BNBEXTRetriever::endSubRun(art::SubRun& sr)
173173
std::cout << "FAILED! " << std::endl;
174174
// probably want to throw an exception here
175175

176-
for(auto ExtInfo : fOutExtInfos){
176+
for(auto &ExtInfo : fOutExtInfos){
177177

178178
ExtInfo.gates_since_last_trigger *= scale_factor;
179179

sbncode/BeamSpillInfoRetriever/BNBRetriever/BNBRetriever_module.cc

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -663,6 +663,8 @@ sbn::BNBSpillInfo sbn::BNBRetriever::makeBNBSpillInfo
663663
double LM875A = 0; // units R/s
664664
double LM875B = 0; // units R/s
665665
double LM875C = 0; // units R/s
666+
double HP873 = 0; // units mm
667+
double VP873 = 0; // units mm
666668
double HP875 = 0; // units mm
667669
double VP875 = 0; // units mm
668670
double HPTG1 = 0; // units mm
@@ -671,6 +673,14 @@ sbn::BNBSpillInfo sbn::BNBRetriever::makeBNBSpillInfo
671673
double VPTG2 = 0; // units mm
672674
double BTJT2 = 0; // units Deg C
673675
double THCURR = 0; // units kiloAmps
676+
double M875HS = 0; // units mm
677+
double M875VS = 0; // units mm
678+
double M875HM = 0; // units mm
679+
double M875VM = 0; // units mm
680+
double M876HS = 0; // units mm
681+
double M876VS = 0; // units mm
682+
double M876HM = 0; // units mm
683+
double M876VM = 0; // units mm
674684

675685
double TOR860_time = 0; // units s
676686

@@ -683,6 +693,8 @@ sbn::BNBSpillInfo sbn::BNBRetriever::makeBNBSpillInfo
683693
try{bfp->GetNamedData(time, "E:LM875A",&LM875A);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
684694
try{bfp->GetNamedData(time, "E:LM875B",&LM875B);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
685695
try{bfp->GetNamedData(time, "E:LM875C",&LM875C);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
696+
try{bfp->GetNamedData(time, "E:HP873",&HP873);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
697+
try{bfp->GetNamedData(time, "E:VP873",&VP873);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
686698
try{bfp->GetNamedData(time, "E:HP875",&HP875);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
687699
try{bfp->GetNamedData(time, "E:VP875",&VP875);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
688700
try{bfp->GetNamedData(time, "E:HPTG1",&HPTG1);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
@@ -691,6 +703,14 @@ sbn::BNBSpillInfo sbn::BNBRetriever::makeBNBSpillInfo
691703
try{bfp->GetNamedData(time, "E:VPTG2",&VPTG2);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
692704
try{bfp->GetNamedData(time, "E:BTJT2",&BTJT2);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
693705
try{bfp->GetNamedData(time, "E:THCURR",&THCURR);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
706+
try{bfp->GetNamedData(time, "E:M875HS",&M875HS);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
707+
try{bfp->GetNamedData(time, "E:M875VS",&M875VS);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
708+
try{bfp->GetNamedData(time, "E:M875HM",&M875HM);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
709+
try{bfp->GetNamedData(time, "E:M875VM",&M875VM);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
710+
try{bfp->GetNamedData(time, "E:M876HS",&M876HS);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
711+
try{bfp->GetNamedData(time, "E:M876VS",&M876VS);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
712+
try{bfp->GetNamedData(time, "E:M876HM",&M876HM);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
713+
try{bfp->GetNamedData(time, "E:M876VM",&M876VM);}catch (WebAPIException &we) {mf::LogDebug("BNBRetriever")<< "At time : " << time << " " << "got exception: " << we.what() << "\n";}
694714

695715
//crunch the times
696716
unsigned long int time_closest_int = (int) TOR860_time;
@@ -703,6 +723,8 @@ sbn::BNBSpillInfo sbn::BNBRetriever::makeBNBSpillInfo
703723
beamInfo.LM875A = LM875A;
704724
beamInfo.LM875B = LM875B;
705725
beamInfo.LM875C = LM875C;
726+
beamInfo.HP873 = HP873;
727+
beamInfo.VP873 = VP873;
706728
beamInfo.HP875 = HP875;
707729
beamInfo.VP875 = VP875;
708730
beamInfo.HPTG1 = HPTG1;
@@ -711,6 +733,14 @@ sbn::BNBSpillInfo sbn::BNBRetriever::makeBNBSpillInfo
711733
beamInfo.VPTG2 = VPTG2;
712734
beamInfo.BTJT2 = BTJT2;
713735
beamInfo.THCURR = THCURR;
736+
beamInfo.M875HS = M875HS;
737+
beamInfo.M875VS = M875VS;
738+
beamInfo.M875HM = M875HM;
739+
beamInfo.M875VM = M875VM;
740+
beamInfo.M876HS = M876HS;
741+
beamInfo.M876VS = M876VS;
742+
beamInfo.M876HM = M876HM;
743+
beamInfo.M876VM = M876VM;
714744
beamInfo.spill_time_s = time_closest_int;
715745
beamInfo.spill_time_ns = time_closest_ns;
716746

sbncode/CAFMaker/CAFMaker_module.cc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1051,7 +1051,6 @@ void CAFMaker::InitializeOutfiles()
10511051

10521052
}
10531053

1054-
10551054
if(fParams.CreateFlatCAF()){
10561055
mf::LogInfo("CAFMaker") << "Output flat filename is " << fFlatCafFilename;
10571056

sbncode/CAFMaker/FillExposure.cxx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ namespace caf
1515
single_store.LM875A = info.LM875A;
1616
single_store.LM875B = info.LM875B;
1717
single_store.LM875C = info.LM875C;
18+
single_store.HP873 = info.HP873;
19+
single_store.VP873 = info.VP873;
1820
single_store.HP875 = info.HP875;
1921
single_store.VP875 = info.VP875;
2022
single_store.HPTG1 = info.HPTG1;
@@ -23,6 +25,14 @@ namespace caf
2325
single_store.VPTG2 = info.VPTG2;
2426
single_store.BTJT2 = info.BTJT2;
2527
single_store.THCURR = info.THCURR;
28+
single_store.M875HS = info.M875HS;
29+
single_store.M875VS = info.M875VS;
30+
single_store.M875HM = info.M875HM;
31+
single_store.M875VM = info.M875VM;
32+
single_store.M876HS = info.M876HS;
33+
single_store.M876VS = info.M876VS;
34+
single_store.M876HM = info.M876HM;
35+
single_store.M876VM = info.M876VM;
2636
single_store.M875BB = info.M875BB;
2737
single_store.M876BB = info.M876BB;
2838
single_store.MMBTBB = info.MMBTBB;

sbncode/Calibration/TrackCaloSkimmer_module.cc

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1140,15 +1140,10 @@ void sbn::TrackCaloSkimmer::FillTrack(const recob::Track &track,
11401140
fTrack->start.x = track.Start().X();
11411141
fTrack->end.x = track.End().X();
11421142
} else if (t0Info.hasT0CRTTrack) {
1143+
int driftDir = geo->TPC(hits[0]->WireID()).DriftDir().X();
11431144
const double driftv(dprop.DriftVelocity(dprop.Efield(), dprop.Temperature()));
1144-
// Comment from Francesco: I am not sure of the below formula.
1145-
// SBND has two TPCs with a common cathode like ICARUS, the driftvelocity
1146-
// returns the absolute value, but the displacement (basically the + below)
1147-
// depends on the TPC, in one case is + and in the other is negative.
1148-
// In this way the displacement is always in the same direction, working for
1149-
// one TPC, but not for the other.
1150-
fTrack->start.x = track.Start().X() + driftv*t0Info.t0CRTTrack*1e-3;
1151-
fTrack->end.x = track.End().X() + driftv*t0Info.t0CRTTrack*1e-3;
1145+
fTrack->start.x = track.Start().X() + driftDir*driftv*t0Info.t0CRTTrack*1e-3;
1146+
fTrack->end.x = track.End().X() + driftDir*driftv*t0Info.t0CRTTrack*1e-3;
11521147
} else if (t0Info.hasT0CRTHit){
11531148
// If the track does not have a a Pandora T0, the tracks will always be either on the left or (ex Or) right of the cathode.
11541149
int driftDir = geo->TPC(hits[0]->WireID()).DriftDir().X();

sbncode/DetSim/FilterSimEnergyDeposits_module.cc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ FilterSimEnergyDeposits::FilterSimEnergyDeposits(fhicl::ParameterSet const& p)
6969
// Call appropriate produces<>() functions here.
7070
// Call appropriate consumes<>() for any products to be retrieved by this module.
7171
produces<std::vector<sim::SimEnergyDeposit>>();
72-
7372

7473
if (fInitSimEnergyDepositLiteLabel != "undefined") { produces<std::vector<sim::SimEnergyDepositLite>>(); }
7574
}

ups/product_deps

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,8 +254,8 @@ libdir fq_dir lib
254254
product version qual flags <table_format=2>
255255
genie_xsec v3_04_00 -
256256
larcv2 v2_2_6 -
257-
larsoft v10_06_00 -
258-
sbnalg v10_06_00_01 -
257+
larsoft v10_06_00_02 -
258+
sbnalg v10_06_00_03 -
259259
sbndaq_artdaq_core v1_10_06 -
260260
sbndata v01_07 -
261261
systematicstools v01_04_04 -

0 commit comments

Comments
 (0)