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

Output descriptive state on CPU when an offloaded track dies #752

Merged
merged 2 commits into from
May 10, 2023

Conversation

sethrj
Copy link
Member

@sethrj sethrj commented May 9, 2023

In combination with #751 :

G4WT1 > ExceptionConverter.cc:153: [2/2] critical: The following error is from: kernel context: track slot 787 in 'geo-boundary', track 501 of event 0
- Particle type: gamma (PDG=22,  ID=0)
- Energy: 0.689991 [MeV]
- Position: {119.121,48.1344,-192.09} (cm)
- Direction: {0.943236,0.244289,0.225008}
- Volume: eregalgo_EBAR@0x6000028a8a00 (ID=1618)
- Surface ID: <invalid>
- Step counter: 71
G4WT1 >
-------- EEEE ------- G4Exception-START -------- EEEE -------
*** G4Exception : celer0004
      issued by : celeritas/ext/detail/GenericPlacedVolume.hh:90
feature is not yet implemented: GenericPlacedVolume
*** Fatal Exception *** core dump ***
G4WT1 > G4Track (0x11c8ca930) - track ID = 0, parent ID = 0

@sethrj sethrj added enhancement New feature or request external Dependencies and framework-oriented features labels May 9, 2023
@sethrj sethrj requested review from amandalund and whokion May 9, 2023 17:34
@@ -76,7 +76,7 @@ void ActionInitialization::Build() const
init_celeritas_});
// Event action saves event ID for offloading and runs queued particles at
// end of event
this->SetUserAction(new EventAction{transport});
this->SetUserAction(new EventAction{params_, transport});
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now, all user actions (TrackingAction, EventAction, RunAction) pass both SharedParam and LocalTransporter. Can SharedParam then be a member of LocalTransporter so that we just pass LocalTransporter, which simplify user action interfaces (in CMSSW too)?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's better to keep them separate because they're serving different purposes and because there's no direct relationship between the two (other than you need the shared params to build the transport and to interpret the exceptions). When we combined the params + state into CoreRef I ended up having to split them apart later, so I'd like to avoid that pitfall again.

}
msg << "\n- Energy: " << kce.energy() << "\n- Position: " << kce.pos()
<< " (cm)"
<< "\n- Direction: " << kce.dir();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add which physics process trigger the exception?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the kernel label may tell us? It's kind of hidden in the top line of the output, but e.g. in the example in the description it's geo-boundary.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes the active kernel, which is output, should give the most accurate picture. I could also add the post step action ID but that would require further changes to the KCE so perhaps a later pr?

}
msg << "\n- Energy: " << kce.energy() << "\n- Position: " << kce.pos()
<< " (cm)"
<< "\n- Direction: " << kce.dir();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess the kernel label may tell us? It's kind of hidden in the top line of the output, but e.g. in the example in the description it's geo-boundary.

@sethrj sethrj merged commit 91c1544 into celeritas-project:develop May 10, 2023
@sethrj sethrj deleted the geant-errors branch May 10, 2023 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request external Dependencies and framework-oriented features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants