Skip to content
This repository has been archived by the owner on Jun 5, 2024. It is now read-only.

AssertionError - Outside the TPC #384

Closed
PavelKavrigin opened this issue Jun 13, 2022 · 0 comments · Fixed by #386
Closed

AssertionError - Outside the TPC #384

PavelKavrigin opened this issue Jun 13, 2022 · 0 comments · Fixed by #386

Comments

@PavelKavrigin
Copy link
Contributor

@terliuk @ramirezdiego : The way the interaction positions from epix instructions are checked sometimes leads to an assertion error even though the interactions are within the TPC:

assert np.all(self.instructions['x']**2 + self.instructions['y']**2 < self.config['tpc_radius']**2), \

assert np.all(self.instructions_epix['x']**2 + self.instructions_epix['y']**2 <

Here's one the files which led to a crash of WFSim with AssertionError during mc_chain run:
/dali/lgrandi/pkavrigin/2022-06-13_WFSim_XYAssertionError/nT_mc_th228_aa_00188.root

These are the corresponding X and Y positions from epix:
/dali/lgrandi/pkavrigin/2022-06-13_WFSim_XYAssertionError/nT_mc_th228_aa_00188.X.npy
/dali/lgrandi/pkavrigin/2022-06-13_WFSim_XYAssertionError/nT_mc_th228_aa_00188.Y.npy

The issue can be reproduced with this notebook:

/dali/lgrandi/pkavrigin/2022-06-13_WFSim_XYAssertionError/2022-06-13_WFSim_XYAssertionError.ipynb

This is apparently a floating-point precision issue.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant