Parallel fill of a histogram This tutorial shows how a histogram can be filled in parallel with a multiprocess approach.
{
auto h =
new TH1F(
"myHist",
"Filled in parallel", 128, -8, 8);
for (
auto i :
ROOT::TSeqI(1000000)) {
h->Fill(
rndm.Gaus(0, 1));
}
};
return 0;
}
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Merge collection of TObjects.
This class provides a simple interface to execute the same task multiple times in parallel,...
1-D histogram with a float per channel (see TH1 documentation)
static void AddDirectory(Bool_t add=kTRUE)
Sets the flag controlling the automatic add of histograms in memory.
Random number generator class based on M.
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
- Date
- January 2016
- Author
- Danilo Piparo
Definition in file mp201_parallelHistoFill.C.