Skip to content

Commit f64b4d4

Browse files
Update with 390 epochs
1 parent da0d0d6 commit f64b4d4

8 files changed

Lines changed: 25 additions & 29 deletions

File tree

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
local_configuration.ini
1+
fnal_tev_configuration.ini

from_dune_tpc/DeepLearning/DataProcessing/DataProcessing_module.cc

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@
2323
#include "larcorealg/Geometry/GeometryCore.h"
2424
#include "lardata/DetectorInfoServices/DetectorPropertiesService.h"
2525

26+
// For beam trigger information
27+
#include "lardataobj/RawData/RDTimeStamp.h"
28+
2629
// DeepLearning includes
2730
#include "dune/Protodune/DeepLearning/Tools/ImageInformation.h"
2831

@@ -360,10 +363,10 @@ namespace ProtoDuneDL
360363
}
361364

362365
auto origin = particleInventory->TrackIdToMCTruth_P(bestTrackId)->Origin();
363-
if((origin == simb::kSingleParticle) && (particleInventory->TrackIdToParticle_P(bestTrackId)->Process() == "primary"))
364-
{
365-
hitOrigin = ProtoDuneDL::Labels::Beam;
366-
}
366+
if((origin == simb::kSingleParticle) && (particleInventory->TrackIdToParticle_P(bestTrackId)->Process() == "primary"))
367+
{
368+
hitOrigin = ProtoDuneDL::Labels::Beam;
369+
}
367370
else
368371
{
369372
hitOrigin = ProtoDuneDL::Labels::NotBeam;
@@ -409,12 +412,27 @@ namespace ProtoDuneDL
409412
pAllHitsStruct->push_back(tempAllHits);
410413
}
411414

412-
// Keep the hit only if it can be matched to the primary
413-
bool keepHit = true;
415+
// Keep the hit only if it can be matched to the primary in MC or event has beam trigger
416+
bool keepHit = false;
414417
if(isMC)
415418
{
416419
keepHit = (mapPrimaryToHits.find(bestTrackId) != mapPrimaryToHits.end()) && (mapPrimaryToHits[bestTrackId] == hitOrigin);
417420
}
421+
else
422+
{
423+
// Require beam trigger
424+
art::Handle<std::vector<raw::RDTimeStamp>> timeStamps;
425+
event.getByLabel("timingrawdecoder:daq", timeStamps);
426+
427+
// Require time stamp and one RDTimeStamp
428+
if(timeStamps.isValid() && timeStamps->size() == 1)
429+
{
430+
// Access the trigger information. Beam trigger flag = 0xc
431+
const raw::RDTimeStamp& timeStamp = timeStamps->at(0);
432+
keepHit = (timeStamp.GetFlags() == 0xc);
433+
}
434+
}
435+
418436
if(keepHit)
419437
{
420438
ProtoDuneDL::HitsStruct tempHits;

from_dune_tpc/DeepLearning/Tools/Constants.h~

Lines changed: 0 additions & 22 deletions
This file was deleted.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)