Closed tdealtry closed 4 years ago
So the log command is basically a wrapper for the cout stream anyway and just using cout is as if its of verbosity level zero.
so i would suggest faking the same operation by doing the following
if(messagelevel<=verbose){
std::stringstream tmp;
tmp<<"["<<messagelevel<<"] "<<message;
std::cout<<tmp.str()<<std::endl;
}
The basis of this pull request is adding to the SubSample class two new vectors
The idea is then that after every trigger tool has found its triggers,
SubSample::TellMeAboutTheTriggers()
is run, which sets these variablesstd::cout
@brichards64 I need your advice for how to turn this into proper logging (could pass it the DataModel's Logging member from the tool, as well as the tool verbosity level?)std::cout
makes it about factor 70 slower when all uncommented...Triggers should also check the
m_masked
bit for each digit, to see if they should use it in their trigger decision. I've implemented this for NHits CPU (unfortunately I had to change the algorithm to handle ignored digits, and the new algorithm appears slower in this test of 100 500 MeV mu- (note these times fluctuate by about a factor 2 on my laptop) but the new algorithm gives identical results to the #30 algorithm - do contribute if you can see any speed increases!)DataOut, BONSAI, etc. should use
m_trigger_readout_windows
, but they are due a rewrites (to be less dependent on WCSim classes), so that will happen in a future PRI've also removed
TriggerInfo::SortByStartTime()
because we don't want trigger numbers changing