-
Notifications
You must be signed in to change notification settings - Fork 46
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
Cell Reading Rewrite, main branch (2024.04.19.) #547
Cell Reading Rewrite, main branch (2024.04.19.) #547
Conversation
Very strange results... Will need to think a little after the meeting. I think that if we do deduplication (and I think that adding activation energies is a good idea) one important thing will be to keep the truth data about which measurement a cell belongs to, which can be more than one. We'll need some way to return this from the |
Well, this has been eye-opening... As it turns out, our code relies on the exact behaviour of So I reverted the global operator to do what it's been doing so far, and made the helper |
165aa58
to
7a673b1
Compare
Made sure that proper comparison operators would exist for traccc::cell and traccc::cell_module, and then just relied on STL containers for ordering the cells and modules correctly in memory.
The truth mapping code (currently) relies on possibly having duplicate cells in the event record, for different particles depositing energy in the same cell. The truth mapping code, and some of the I/O unit tests, are now set up to disable the cell de-duplication during CSV reading. Reverted to the previous ordering scheme for traccc::cell-s, and implemented a (different) custom ordering for the cell collection. Since as it turns out, the project implicitly relies on these two behaving a little differently.
This way it becomes possible to sum up the activations of the cells, using the value in the map.
7a673b1
to
1be9b1a
Compare
This ended up being an alternative for #546. 🤔
In here I made sure that proper comparison operators would exist for
traccc::cell
andtraccc::cell_module
, and then just relied on STL containers for ordering the cells and modules correctly in memory. Instead of the nigh unreadable current logic of the code.We are looking at this with @stephenswat right now because of #527. Just as #546, this update also ensures that there would not be any duplicate cells read in from the CSV files. Which activates the same unit test failures.
But even more weirdly, this still doesn't answer the mystery that we've been struggling with Stephen for the last hour. You see, Stephen prepared some ODD files that would exclude the duplicated cells. But something really weird is going on with those files. Because the host seeding code does not find any seeds when reading those files. While it finds plenty with the files containing the duplicate cells.
But, even more weirdly, with this PR's code, I see the following using the CUDA test:
So, something weird went wrong with the file updates, and I can just not figure out what. 😕 But at the same time, I think we should just go ahead with this deduplication in the code, and make sure that the tests would be made to work with the deduplication included. 🤔