Add run number changed hook, use it to lazy-load reverse translation table#91
Add run number changed hook, use it to lazy-load reverse translation table#91raffaelladevita merged 6 commits intomainfrom
Conversation
| @Override | ||
| public void processEvent(DataEvent event) { | ||
|
|
||
| if (reverse == null) reverse = getReverseTT(forward); |
There was a problem hiding this comment.
reverse needs to be rebuilt if the run number changes because forward can be different. That's why getReverseTT was called in createHistos
There was a problem hiding this comment.
then need to check run number changed
There was a problem hiding this comment.
are there other options?
There was a problem hiding this comment.
createHistos is called at the start, if the run number changes, and when a manual or automatic reset is issued.
if getReverseTT is called in createHistos, it will be executed in the three cases listed above. The first (at the start) is not really useful because the run number is not known yet and could be skipped with a check on run number being non-zero
There was a problem hiding this comment.
we should really avoid blocking the UI for 10+ seconds if feasible
|
much faster, not sure it's equal ... |
in preparation to see if it can be sped up