Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patches to KF-based Alignment Pipeline #938

Merged
merged 10 commits into from
Dec 5, 2022
Merged

Patches to KF-based Alignment Pipeline #938

merged 10 commits into from
Dec 5, 2022

Conversation

tomeichlersmith
Copy link
Collaborator

@tomeichlersmith tomeichlersmith commented Dec 2, 2022

This PR contains a few small but important changes to the KF-based alignment pipeline that are required for it to function properly.

  1. @pbutti implemented the delete method for GblTrajectoryJna which is necessary to avoid a memory leak causing the alignment pipeline to crash on some systems. This crash was more common with KF-based alignment since KF produced more tracks which therefore created more GBL trajectories which therefore leaked more memory.
  2. Since GBL tracker hits consist of two sensors, the "n-hits" cut for GBL is actually half of what it should be for KF. The previous implementation of doubling this cut accidentally doubled the cut on each track which meant the variable holding the cut quickly overflowed and returned to zero, meaning a lot of low-quality KF tracks were being included in the alignment. This patch simply calculates the "actual n hit cut" depending on the type of track on each track, storing the result in a new variable.
  3. Some KF tracks are not refit with a GBL trajectory properly and so we need to check that the resulting GBL trajectory is non-null before proceeding.

To Do

  • Make sure code format is proper
  • Make sure code still passes current tests
  • Update documentation comments
  • Cleanup commit history

pbutti and others added 5 commits December 2, 2022 08:45
this was causing the cut to eventually overflow and go down to zero
allowing all tracks to pass the hit cut, defining a local variable
allows the cut to change depending on the type of track (KF or GBL)
@pbutti pbutti self-requested a review December 2, 2022 14:45
- apply nhits cut in a way that makes it obvious which track type uses
  which cut
- multiply nhits by 2 if the hits stored in the tracker are helicalcross
  which is really a combination of 2 tracker hits to make a 3D point
- the debug printout should be a warning since the user should not be
  seeing it if they are using the drivers properly
- add some more comments explaining rational for code and potential
  roadmap
- remove unnecessary total counting of tracks
@cbravo135 cbravo135 merged commit 0394d86 into JeffersonLab:master Dec 5, 2022
@tomeichlersmith tomeichlersmith deleted the tomeichlersmith/traj-ali-nhits-cut branch December 5, 2022 18:58
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants