DUNE / ND_CAFMaker

Code for making CAFs from ND inputs (whether 2x2+MINERvA prototype or full ND simulation)
Apache License 2.0
1 stars 11 forks source link

Trigger erasing fix proposition #57

Closed noeroy closed 7 months ago

noeroy commented 7 months ago

Some Minirun4.5 jobs were failing at the trigger filling procedure, on test I've run, it seems that it happens even more with MINERvA only events.

As I understand it, the erase statement in the trigger matching for loop seem to remove an element we try to access to afterwards https://github.com/DUNE/ND_CAFMaker/blob/main/src/makeCAF.C#L278

Modify with storing the keys to erase and remove them outside the for loop that contains the map. On tests, I see the same number of triggers and files that crashed don't crash anymore.

Joint here are two valgrind files running on the same files to make CAFs. I'm not a valgrind expert but the ==4445== Invalid read of size 8 that seem to be associated to buildTriggerList have disapeared in the postfix version, so I assume that fixed some memory issue somewhere? logfile_valigrind_postfix.txt logfile_valigrind_prefix.txt