diff --git a/CMakeLists.txt b/CMakeLists.txt index d797dc2d1..cb8c49e67 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,7 +16,7 @@ cmake_minimum_required(VERSION 3.20 FATAL_ERROR) find_package(cetmodules 3.20.00 REQUIRED) -project(sbncode VERSION 10.14.02.03 LANGUAGES CXX) +project(sbncode VERSION 10.15.00 LANGUAGES CXX) message(STATUS "\n\n ========================== ${PROJECT_NAME} ==========================") diff --git a/sbncode/CAFMaker/CAFMakerParams.h b/sbncode/CAFMaker/CAFMakerParams.h index 0250e740f..f89a29ef0 100644 --- a/sbncode/CAFMaker/CAFMakerParams.h +++ b/sbncode/CAFMaker/CAFMakerParams.h @@ -635,6 +635,11 @@ namespace caf "cvn" }; + Atom fBlipTag { + Name("BlipTag"), + Comment("Provide a string to label the blip input"), + "blipReco" + }; }; } diff --git a/sbncode/CAFMaker/CAFMaker_module.cc b/sbncode/CAFMaker/CAFMaker_module.cc index 9f2c01590..46c1d475c 100644 --- a/sbncode/CAFMaker/CAFMaker_module.cc +++ b/sbncode/CAFMaker/CAFMaker_module.cc @@ -20,6 +20,7 @@ #include "sbncode/CAFMaker/FillExposure.h" #include "sbncode/CAFMaker/FillTrigger.h" #include "sbncode/CAFMaker/Utils.h" +#include "sbncode/CAFMaker/FillBlip.h" // C/C++ includes #include @@ -1928,6 +1929,13 @@ void CAFMaker::produce(art::Event& evt) noexcept { } } + //Fill blips. art::handle for blips and then call fill blips for each one. Make a vector to hold all of them. I handle for loop in Fill blip + art::Handle> blipHandle; + std::vector srblips; + if(evt.getByLabel( fParams.fBlipTag(), blipHandle)) //fill SR blips + { + FillBlip( *blipHandle, srblips); + } // collect the TPC slices std::vector> slices; std::vector slice_tag_suffixes; @@ -2605,6 +2613,7 @@ void CAFMaker::produce(art::Event& evt) noexcept { rec.sbnd_crt_veto = srsbndcrtveto; rec.opflashes = srflashes; rec.nopflashes = srflashes.size(); + rec.blips = srblips; rec.sbnd_frames = srsbndframeshiftinfo; rec.sbnd_timings = srsbndtiminginfo; rec.soft_trig = srsbndsofttrig; diff --git a/sbncode/CAFMaker/CMakeLists.txt b/sbncode/CAFMaker/CMakeLists.txt index 5dd4f2a8f..7ffa9eb93 100644 --- a/sbncode/CAFMaker/CMakeLists.txt +++ b/sbncode/CAFMaker/CMakeLists.txt @@ -39,6 +39,7 @@ art_make_library( LIBRARY_NAME sbncode_CAFMaker sbnobj::Common_Trigger sbnobj::SBND_CRT sbnobj::SBND_Timing + sbnobj::SBND_Blip lardataalg::DetectorInfo art::Framework_Services_System_TriggerNamesService_service sbncode_Metadata_MetadataSBN_service diff --git a/sbncode/CAFMaker/FillBlip.cxx b/sbncode/CAFMaker/FillBlip.cxx new file mode 100644 index 000000000..5d71edb35 --- /dev/null +++ b/sbncode/CAFMaker/FillBlip.cxx @@ -0,0 +1,96 @@ +#include "sbncode/CAFMaker/FillBlip.h" + +namespace caf +{ + void FillBlip( const std::vector& LAr_Blips, std::vector& CAF_Blips) + { + for(blip::Blip const& CurrentBlip: LAr_Blips) + { + caf::SRBlip NewBlip; + NewBlip.ID = CurrentBlip.ID; + NewBlip.isValid = CurrentBlip.isValid; + NewBlip.cryostat = CurrentBlip.Cryostat; + NewBlip.TPC = CurrentBlip.TPC; + NewBlip.nPlanes = CurrentBlip.NPlanes; + NewBlip.maxWireSpan = CurrentBlip.MaxWireSpan; + NewBlip.timeTick = CurrentBlip.TimeTick; + NewBlip.time = CurrentBlip.Time; + NewBlip.charge = CurrentBlip.Charge; + NewBlip.energy = CurrentBlip.Energy/1000.; //convert to GeV + NewBlip.energyESTAR = CurrentBlip.EnergyESTAR/1000.; //convert to GeV + NewBlip.energyPSTAR = CurrentBlip.EnergyPSTAR/1000.; //convert to GeV + NewBlip.proxTrkDist = CurrentBlip.ProxTrkDist; + NewBlip.proxTrkID = CurrentBlip.ProxTrkID; + NewBlip.inCylinder = CurrentBlip.inCylinder; + NewBlip.position.SetXYZ(CurrentBlip.Position.X(), CurrentBlip.Position.Y(), CurrentBlip.Position.Z()); + NewBlip.sigmaYZ = CurrentBlip.SigmaYZ; + NewBlip.dX = CurrentBlip.dX; + NewBlip.dYZ = CurrentBlip.dYZ; + if(CurrentBlip.truth.ID >= 0 ) //MC Blip + { + FillMCTruthBlip( CurrentBlip.truth, NewBlip.truthBlip ); + } + for(int iPlane=0; iPlane + +namespace caf +{ + + void FillBlip( const std::vector& LAr_Blips, std::vector& CAF_Blips); + void FillMCTruthBlip( blip::TrueBlip const & TrueLAr_Blip, caf::SRTrueBlip &TrueCAF_Blip ); + void FillBlipRelatedHitCluster(blip::HitClust const & LAr_HitClust, caf::SRBlipHitClust &CAF_HitClust); +} + +#endif diff --git a/ups/product_deps b/ups/product_deps index 483437ae1..bd64268c1 100644 --- a/ups/product_deps +++ b/ups/product_deps @@ -252,14 +252,14 @@ libdir fq_dir lib # #################################### product version qual flags -genie_xsec v3_06_02_sbn2 - +genie_xsec v3_06_00 - larcv2 v2_2_6 - -larsoft v10_14_02_02 - -sbnalg v10_14_02_01 - +larsoft v10_15_00 - +sbnalg v10_15_00 - sbndaq_artdaq_core v1_10_06 - sbndata v01_08 - systematicstools v01_04_04 - -nusystematics v1_05_10sbn02 - +nusystematics v1_05_10 - geant4reweight v01_20_14 - cetmodules v3_24_01 - only_for_build end_product_list @@ -317,10 +317,10 @@ end_product_list # #################################### qualifier larsoft sbnalg sbndaq_artdaq_core genie_xsec sbndata larcv2 systematicstools nusystematics geant4reweight notes -c14:debug c14:debug c14:debug c14:s131:debug AR2520i00000:e1000:k250 -nq- c14:debug:p3915 c14:debug c14:debug c14:debug:s131 -nq- -c14:prof c14:prof c14:prof c14:s131:prof AR2520i00000:e1000:k250 -nq- c14:p3915:prof c14:prof c14:prof c14:prof:s131 -nq- -e26:debug e26:debug e26:debug e26:s131:debug AR2520i00000:e1000:k250 -nq- debug:e26:p3915 e26:debug e26:debug e26:debug:s131 -nq- -e26:prof e26:prof e26:prof e26:s131:prof AR2520i00000:e1000:k250 -nq- e26:p3915:prof e26:prof e26:prof e26:prof:s131 -nq- +c14:debug c14:debug c14:debug c14:s131:debug AR2320i00000:e1000:k250 -nq- c14:debug:p3915 c14:debug c14:debug c14:debug:s131 -nq- +c14:prof c14:prof c14:prof c14:s131:prof AR2320i00000:e1000:k250 -nq- c14:p3915:prof c14:prof c14:prof c14:prof:s131 -nq- +e26:debug e26:debug e26:debug e26:s131:debug AR2320i00000:e1000:k250 -nq- debug:e26:p3915 e26:debug e26:debug e26:debug:s131 -nq- +e26:prof e26:prof e26:prof e26:s131:prof AR2320i00000:e1000:k250 -nq- e26:p3915:prof e26:prof e26:prof e26:prof:s131 -nq- end_qualifier_list ####################################