Skip to content

Conversation

@brownd1978
Copy link
Collaborator

@brownd1978 brownd1978 commented Feb 1, 2026

This PR removes BTrk and all references to its dependencies, in particular KalRep, from the Mu2e codebase.
A few deeply-embedded references to low-level BTrk classes, mostly in CalPatRec, have been left. To satisfy those dependeices, truncated versions of a handful of BTrk classes were moved to the new Mu2e package BTrkLegacy. Those are all marked as deprecated, and all uses of them should be either retired or refactored to use modern equivalents eventually.

The BTrkData, Mu2eBTrk, TrkExt, TrackCaloMatch directories have been removed, as they depended in detailed ways on BTrk structures in their implementation, and their functionality has been replaced with superior codes using KinKal track.

The TrackSummary* classes have been stripped of their BTrk dependencies, which renders them useless. I believe these have all been superseded by other analysis classes, these entire directories should probably be removed.

TEveEventDisplay had many BTrk dependencies: those have been stripped out to get the code to compile, but not tested. This package has been replaced by EventDisplay and should be removed.

Proditions services tied to BTrk (mu2eDetector and mu2eMaterial) have been disabled, but may still have some residue.

Both spack and muse builds have been tested. The link dependence on BTrk in the spack build was removed in my test, but changes outside Offline are required to make that permanent. The scons build still pulls in BTrk libraries, that needs to be fixed in another repo.

Followup changes are also required in EventNtuple and EventDisplay, those are submitted in separate PRs. Other repos (stntuple? tutorial?) may also require updates. It's also possible there are BTrk references in Offline in non-standard locations.

There is followup work also to remove BTrk-related data members in KalSegment, and maybe other classes.

These changes have been shown to produce functional output running reconstruction, primary generation, and digitization, using the slack build.

This PR is largely the work of Jason Guo, an undergraduate student at UCB.

Jasonguo9019 and others added 30 commits October 9, 2025 21:57
…le.cc, commented out TrkPatRec/src/KalFinalFitDiag_tool.cc and TrkPatRec/src/KalFinalFit_module.cc
…doublet.hh in CalTimePeakFinder_module, removed MergeHelixFinder_module, removed DoubletAmbigResolver
…rkUtilities and BTrk includse in Trkutilities
…dule.hh, and got rid of unused includes in CalPatRec/inc/CalHelixFinder_module.hh, which only needs HelixTraj.hh
…er_module.cc and CalPatRec/src/ObjectDumpUtils.cc
merge current Offline main
@brownd1978
Copy link
Collaborator Author

@FNALbuild run build test

@FNALbuild
Copy link
Collaborator

⌛ The following tests have been triggered for 4c5637c: build (Build queue - API unavailable)

@FNALbuild
Copy link
Collaborator

☔ The build tests failed for 4c5637c.

Test Result Details
test with Command did not list any other PRs to include
merge Merged 4c5637c at 4f1ca06
build (prof) Log file. Build time: 08 min 57 sec
ceSimReco Log file. Return Code 90.
g4test_03MT Log file. Return Code 90.
transportOnly Log file. Return Code 90.
POT Log file.
g4study Log file. Return Code 90.
cosmicSimReco Log file. Return Code 90.
cosmicOffSpill Log file. Return Code 90.
ceSteps Log file.
ceDigi Log file. Return Code 90.
muDauSteps Log file.
ceMix Log file. Return Code 90.
rootOverlaps Log file. Return Code 90.
g4surfaceCheck Log file. Return Code 90.
trigger Log file. Return Code 2.
check_cmake Log file.
FIXME, TODO ➡️ TODO (13) FIXME (42) in 206 files
clang-tidy ➡️ 69 errors 2789 warnings
whitespace check ➡️ found whitespace errors

N.B. These results were obtained from a build of this Pull Request at 4c5637c after being merged into the base branch at 4f1ca06.

For more information, please check the job page here.
Build artifacts are deleted after 5 days. If this is not desired, select Keep this build forever on the job page.

@brownd1978
Copy link
Collaborator Author

@FNALbuild run build test

@FNALbuild
Copy link
Collaborator

⌛ The following tests have been triggered for 6aa47d8: build (Build queue - API unavailable)

@FNALbuild
Copy link
Collaborator

☀️ The build tests passed at 6aa47d8.

Test Result Details
test with Command did not list any other PRs to include
merge Merged 6aa47d8 at 4f1ca06
build (prof) Log file. Build time: 04 min 13 sec
ceSimReco Log file.
g4test_03MT Log file.
transportOnly Log file.
POT Log file.
g4study Log file.
cosmicSimReco Log file.
cosmicOffSpill Log file.
ceSteps Log file.
ceDigi Log file.
muDauSteps Log file.
ceMix Log file.
rootOverlaps Log file.
g4surfaceCheck Log file.
trigger Log file.
check_cmake Log file.
FIXME, TODO ➡️ TODO (13) FIXME (43) in 207 files
clang-tidy ➡️ 71 errors 2828 warnings
whitespace check ➡️ found whitespace errors

N.B. These results were obtained from a build of this Pull Request at 6aa47d8 after being merged into the base branch at 4f1ca06.

For more information, please check the job page here.
Build artifacts are deleted after 5 days. If this is not desired, select Keep this build forever on the job page.

Copy link
Collaborator

@rlcee rlcee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have spot checked several files and taken a closer look at a few things that I am familiar with, like Proditions. I don't see anything of any particular concern. Congrats on this big step.

@oksuzian oksuzian merged commit 1148372 into Mu2e:main Feb 4, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants