Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
RDataSource.cxx
Go to the documentation of this file.
5
6#ifdef R__USE_IMT
7#include <ROOT/RSlotStack.hxx>
9#endif
10
12 const std::unordered_map<std::string, ROOT::RDF::Experimental::RSample *> &) const
13{
14 // Currently not implemented for the generic data source, only works correctly for TTree.
15 // TODO: Implement the feature also for the generic data source.
17}
18
20{
21#ifdef R__USE_IMT
23 std::atomic<ULong64_t> entryCount(0ull);
25
26 auto ranges = GetEntryRanges();
27 while (!ranges.empty()) {
28 pool.Foreach(
29 [&lm, &slotStack, &entryCount](const std::pair<ULong64_t, ULong64_t> &range) {
30 lm.DataSourceThreadTask(range, slotStack, entryCount);
31 },
32 ranges);
33 ranges = GetEntryRanges();
34 }
35
36 if (fGlobalEntryRange.has_value()) {
37 auto &&[begin, end] = fGlobalEntryRange.value();
38 auto &&processedEntries = entryCount.load();
39 if ((end - begin) > processedEntries) {
40 Warning("RDataFrame::Run",
41 "RDataFrame stopped processing after %lld entries, whereas an entry range (begin=%lld,end=%lld) was "
42 "requested. Consider adjusting the end value of the entry range to a maximum of %lld.",
43 processedEntries, begin, end, begin + processedEntries);
44 }
45 }
46#else
47 (void)lm;
48#endif
49}
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
Definition TError.cxx:229
The head node of a RDF computation graph.
A thread-safe list of N indexes (0 to size - 1).
friend ROOT::RDF::RSampleInfo ROOT::Internal::RDF::CreateSampleInfo(const ROOT::RDF::RDataSource &, const std::unordered_map< std::string, ROOT::RDF::Experimental::RSample * > &)
friend void ROOT::Internal::RDF::ProcessMT(RDataSource &, ROOT::Detail::RDF::RLoopManager &)
This type represents a sample identifier, to be used in conjunction with RDataFrame features such as ...
This class provides a simple interface to execute the same task multiple times in parallel threads,...