cmssw icon indicating copy to clipboard operation
cmssw copied to clipboard

[mkFit] fix charge flip bug in propagationToPlane

Open leonardogiannini opened this issue 1 week ago • 10 comments

PR description:

This PR fixes the mkFit propagation to plane to allow for charge flips during the propagation.

  • inside kalmanOperationPlaneLocal the sign of 1/pT (outPar(n,3,0) is set negative in case of charge flips, so that the safeguard can catch the charge flip here

  • the sign of the jacobian element jacCurv2CCS(n, 3, 0) is also changed as the charge enters it directly.

PR validation:

The change has a small effect on mkFit built tracks, visible for instance at HLT with legacy tracking (MTV_TTPU), where the number of hits increases slightly (blue=before, red=after fix)

image

The effect is negligible in the HLT tracking proposed new baseline, or patatrack extension + LST seeding single iteration (see plots)

The most noticeable improvement is observed when mkFit is used in the final fit, where the problem was found. E.g. for 10 GeV muons (blue = CKF fit, red = mkFit, with legacy HLT tracking, hltInitialStepTracks), we can see that right tail at high pT due to the missing charge flips disappears in right plot, after the fix.

image

NB: the mkFit fit is not currently part of any baseline tracking configuration.

leonardogiannini avatar Dec 12 '25 17:12 leonardogiannini

cms-bot internal usage

cmsbuild avatar Dec 12 '25 17:12 cmsbuild

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-49622/47160

cmsbuild avatar Dec 12 '25 17:12 cmsbuild

A new Pull Request was created by @leonardogiannini for master.

It involves the following packages:

  • RecoTracker/MkFitCore (reconstruction)

@Moanwar, @cmsbuild, @jfernan2, @mandrenguyen, @srimanob can you please review it and eventually sign? Thanks. @GiacomoSguazzoni, @VinInn, @VourMa, @dgulhan, @elusian, @felicepantaleo, @gpetruc, @makortel, @mmasciov, @mmusich, @mtosi, @rovere this is something you requested to watch as well. @ftenchini, @mandrenguyen, @sextonkennedy you are the release manager for this.

cms-bot commands are listed here

cmsbuild avatar Dec 12 '25 17:12 cmsbuild

test parameters:

  • enable = hlt_p2_integration, hlt_p2_timing
  • workflows = ph2_hlt

mmasciov avatar Dec 12 '25 17:12 mmasciov

please test

mmasciov avatar Dec 12 '25 17:12 mmasciov

test parameters:

  • enable = hlt_p2_integration, hlt_p2_timing
  • workflows = ph2_hlt

As this is currently mostly relevant for phase-2 HLT (FYI @mmusich)

mmasciov avatar Dec 12 '25 17:12 mmasciov

did the bot get stuck?

slava77 avatar Dec 13 '25 18:12 slava77

+1

Size: This PR adds an extra 32KB to repository Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-e8fabd/49934/summary.html COMMIT: 0b9519d8925cb48eefe68180634c9f15b474c3a6 CMSSW: CMSSW_16_0_X_2025-12-12-1100/el8_amd64_gcc13 Additional Tests: HLT_P2_INTEGRATION,HLT_P2_TIMING User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/49622/49934/install.sh to create a dev area with all the needed externals and cmssw changes.

HLT P2 Timing: chart

Comparison Summary

Summary:

  • You potentially added 2 lines to the logs
  • ROOTFileChecks: Some differences in event products or their sizes found
  • Reco comparison results: 10 differences found in the comparisons
  • Reco comparison had 4 failed jobs
  • DQMHistoTests: Total files compared: 73
  • DQMHistoTests: Total histograms compared: 5017231
  • DQMHistoTests: Total failures: 472
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 5016739
  • DQMHistoTests: Total skipped: 20
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 72 files compared)
  • Checked 295 log files, 253 edm output root files, 73 DQM output files
  • TriggerResults: no differences found

cmsbuild avatar Dec 13 '25 23:12 cmsbuild

+1

jfernan2 avatar Dec 15 '25 12:12 jfernan2

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @mandrenguyen, @ftenchini, @sextonkennedy (and backports should be raised in the release meeting by the corresponding L2)

cmsbuild avatar Dec 15 '25 12:12 cmsbuild

+1

mandrenguyen avatar Dec 15 '25 20:12 mandrenguyen

type bug-fix

mmusich avatar Dec 15 '25 21:12 mmusich