Skip to content

Removed electron drift electrons starting at z > -1 cm#296

Closed
sebvetter wants to merge 5 commits intomainfrom
electron_drift_fix
Closed

Removed electron drift electrons starting at z > -1 cm#296
sebvetter wants to merge 5 commits intomainfrom
electron_drift_fix

Conversation

@sebvetter
Copy link
Copy Markdown
Contributor

What does the code in this PR do / what does it improve?

The default field distortion map only extends up to z = -1 cm, afterwards it extrapolates. Electrons at the very top of the TPC do not drift and need to field distortion. Therefore I removed the application of the FDC for z > -1 cm.

Can you briefly describe how it works?

Make a selection of events with z < -1cm and apply the field distortion on the selected events (instead of all).

Can you give a minimal working example (or illustrate with a figure)?

electron_drift_use_fdc_for_top
Before the fix: The position in the instructions and the position at the interface are not the same because of electron drift.

electron_drift_no_fdc_for_top
After the fix: The instructed position and the interface position are the same (only electrons starting at z = -0.1cm shown).

Please include the following if applicable:

  • Update the docstring(s)
  • Bump plugin version(s)
  • Update the documentation
  • Tests to check the (new) code is working as desired.
  • Does it solve one of the GitHub open issues?

@coveralls
Copy link
Copy Markdown

coveralls commented Mar 4, 2025

Pull Request Test Coverage Report for Build 14465814572

Details

  • 5 of 5 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.07%) to 77.987%

Totals Coverage Status
Change from base Build 14359187849: -0.07%
Covered Lines: 2565
Relevant Lines: 3289

💛 - Coveralls

@sebvetter sebvetter self-assigned this Mar 4, 2025
@HenningSE
Copy link
Copy Markdown
Collaborator

@sebvetter Is this PR ready for review?

@sebvetter
Copy link
Copy Markdown
Contributor Author

Not yet, the boundary is currently hardcoded. The better way, in my eyes, is to set the fill value for out of bounds points of the interpolator to 0. I will try and get to testing this in the near future

@cfuselli
Copy link
Copy Markdown
Member

Closed in favour of #304

@cfuselli cfuselli closed this Apr 28, 2025
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.

5 participants