Repository navigation
MCS momentum fit for ICARUS: Gran Sasso algorithm update - #940
Open
giovannichiello wants to merge 10 commits into
Open
giovannichiello wants to merge 10 commits into
giovannichiello wants to merge 10 commits into
Conversation
… lies in the last logical TPC
mvicenzi
requested changes
Nov 17, 2026
Member
There was a problem hiding this comment.
Hi @giovannichiello -- thanks for this! I noticed you’re adding a new data product, recob::MCSFitResultGS, in icaruscode (icaruscode/TPC/Tracking/MCS/MCSFitResultGS.h/.cxx, plus the dictionary entries).
Is the end goal to use this product to fill variables in the CAF?
If so, icaruscode is not the right place for it.
The CAFMaker lives in sbncode so it won't be able to include the header or read this product.
I strongly suggest moving the data product directly in sbnobj:
- Move
MCSFitResultGS.h/.cxxand theirclasses.h/classes_def.xmlentries to a suitable place insbnobj(e.g. next to the other ICARUS or common reco products), and open a companion PR. - Keep the producer (
MCSFitProducerICARUS) and the fitter (trkf::TrajectoryMCSFitterICARUS) here, and have them include the header fromsbnobj.
You could move it later, but it would be a pain.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MCS momentum fit for ICARUS: Gran Sasso algorithm update (producer, fitter and data product)
This PR updates the Multiple Coulomb Scattering (MCS) momentum fit in
icaruscode/TPC/Tracking/MCS:the producer
MCSFitProducerICARUS, the fittertrkf::TrajectoryMCSFitterICARUSand the data productrecob::MCSFitResultGS.Producer (
MCSFitProducerICARUS_module.cc)selectionMode:0is default and applies the cosmic stopping-muon selection(same cuts as
TrackCaloSkimmer), other selection cuts are on their way.Fitter (
TrajectoryMCSFitterICARUS)segmentLength, with a forced break at the cathode crossing.UsePoint) applies the plane (planeMode), the cathode distance(cathode position from
TPCGeo::GetCathodeCenter()required to be greater than 15 cm) and the TPC, according tofullTrackMode.0= first TPC1= last TPC2= full trackfullTrackMode = 2.ThetaCheckreturns the window of segments used in the fit, and the same window is used byfitMcs, the C2 function and the likelihood.0and1use the longest contiguous run of valid angles.2goes from the first to the last valid angle, skipping holes such as the cathode crossing.minNumSegments.ScanResultC2. When the fit fails or is out of range, the linear interpolationfallback reuses the existing scan. If C2 never crosses 1, the momentum
is set to the edge of the fit range, with the full range as error.
ScanResultLLwith best momentum, asymmetric errors (ΔNLL = 0.5),minimum NLL and the full scan.
verbose(0/1/2).Data product (
MCSFitResultGS)classes_def.xml.