32 static RLogChannel
sLog(
"ROOT.RNTupleExporter");
36struct RColumnExportInfo {
52struct RAddColumnsResult {
72 const RNTupleExporter::RPagesOptions &options)
77 RAddColumnsResult res{};
111RNTupleExporter::RPagesResult
122 auto desc =
source.GetSharedDescriptorGuard();
153 auto colElement = ROOT::Internal::RColumnElementBase::Generate<void>(
colInfo.fColDesc->GetType());
159 <<
"exporting column \"" <<
colInfo.fQualifiedName <<
"\" (" <<
pages.GetPageInfos().size() <<
" pages)";
169 std::ostringstream
ss{options.
fOutputPath, std::ios_base::ate};
172 <<
"_elems_" <<
pageInfo.GetNElements() <<
"_comp_" << *
colRange.GetCompressionSettings() <<
".page";
177 R__FAIL(std::string(
"output path ") + options.
fOutputPath +
" does not exist or is not writable!"));
215 std::ostringstream
ss;
#define R__FAIL(msg)
Short-hand to return an RResult<T> in an error state; the RError is implicitly converted into RResult...
#define R__LOG_DEBUG(DEBUGLEVEL,...)
const ROOT::RFieldDescriptor * fFieldDesc
std::string fQualifiedName
const ROOT::RColumnDescriptor * fColDesc
static void AddColumnsFromField(std::vector< RColumnMergeInfo > &columns, const ROOT::RNTupleDescriptor &srcDesc, const FieldCollectionMap_t< RColReprMapping > &colReprMappings, RNTupleMergeData &mergeData, const ROOT::RFieldDescriptor &srcFieldDesc, const ROOT::RFieldDescriptor &dstFieldDesc, const std::string &prefix="")
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
#define R__ASSERT(e)
Checks condition e and reports a fatal error if it's false.
std::string & operator+=(std::string &left, const TString &right)
@ kBlacklist
Don't export items contained in the filter's set.
static RPagesResult ExportPages(ROOT::Internal::RPageSource &source, const RPagesOptions &options={})
Given a page source, writes all its pages to individual files (1 per page).
Managed a set of clusters containing compressed and packed pages.
An in-memory subset of the packed and compressed pages of a cluster.
std::unordered_set< ROOT::DescriptorId_t > ColumnSet_t
static void Unzip(const void *from, size_t nbytes, size_t dataLen, void *to)
The nbytes parameter provides the size ls of the from buffer.
A page as being stored on disk, that is packed and compressed.
Abstract interface to read data from an ntuple.
Metadata stored for every column of an RNTuple.
Base class for all ROOT issued exceptions.
Metadata stored for every field of an RNTuple.
A log configuration for a channel, e.g.
The on-storage metadata of an RNTuple.
const_iterator end() const
std::unordered_set< T > fSet
RFilter< ENTupleColumnType > fColumnTypeFilter
Optional filter that determines which columns are included or excluded from being exported.
@ kDecompress
If enabled, uncompress (but don't unpack) the page (mutually exclusive with kIncludeChecksums)
@ kShowProgressBar
If enabled, the exporter will report the current progress on the stderr.
std::vector< std::string > fExportedFileNames
On-disk pages within a page source are identified by the column and page number.