Skip to content

Stream crystal hits to "UC" instead of "UH" in ROA output#156

Open
fhagemann wants to merge 1 commit into
cositools:develop/emfrom
fhagemann:CrystalHits
Open

Stream crystal hits to "UC" instead of "UH" in ROA output#156
fhagemann wants to merge 1 commit into
cositools:develop/emfrom
fhagemann:CrystalHits

Conversation

@fhagemann

@fhagemann fhagemann commented May 27, 2026

Copy link
Copy Markdown

Currently, when running simulations with the EM massmodels, the current implementation of the DEE results in MStripHits and MCrystalHits both being saved to UH to the ROA file. This messes up parsing these ROA files, because the rows for crystal hits have fewer entries:
Screenshot from 2026-05-27 09-15-01

I was wondering whether UH here is actually correct, or whether it should be exclusively reserved for MStripHits.
It looks like MShieldCrystalHits for example are saved to UC instead of UH:

void MShieldCrystalHit::StreamRoa(ostream& S, bool WithADC, bool WithEnergy, bool WithFlags, bool WithOrigins)
{
//! Stream the content in MEGAlib's evta format
S<<"UC "

whereas MCrystalHits are saved to UH:

void MCrystalHit::StreamRoa(ostream& S, bool WithADC, bool WithEnergy, bool WithFlags, bool WithOrigins)
{
//! Stream the content in MEGAlib's evta format
S<<"UH "

Writing MCrystalHits also to UC instead of UH would prevent my current scripts from failing in case ACS hits are present in the simulations 😇

@zoglauer

Copy link
Copy Markdown
Collaborator

Let me think about this - the roa / UH format is the universal format to get stuff into melinator.

@zoglauer

Copy link
Copy Markdown
Collaborator

The dat format was originally intended to just store all the information which was in the class.

@zoglauer

Copy link
Copy Markdown
Collaborator

we just stopped updating it at some point in time.

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.

2 participants