Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
ROOT::Experimental::Internal::ML::RNTupleBatchSink Class Referencefinal

Writes batches into an RNTuple, as one float field per scalar column and one std::vector<float> field per vector column.

Definition at line 100 of file RBatchSink.hxx.

Public Member Functions

 RNTupleBatchSink (const RNTupleBatchSink &)=delete
 
 RNTupleBatchSink (RNTupleBatchSink &&)=delete
 
 RNTupleBatchSink (std::string_view dataset_name, std::string_view filename, std::vector< RColumnLayout > layout)
 
 ~RNTupleBatchSink () override
 
void Commit () override
 Flush everything to disk once after the last batch.
 
void FillBatch (const RFlat2DMatrix &batch)
 Write every row of batch.
 
void FillRow (const float *row) override
 Copy one row of fRowWidth floats into the writer's buffers and write the entry.
 
RNTupleBatchSinkoperator= (const RNTupleBatchSink &)=delete
 
RNTupleBatchSinkoperator= (RNTupleBatchSink &&)=delete
 

Protected Attributes

std::vector< RColumnLayoutfLayout
 
std::size_t fRowWidth {}
 

Private Attributes

std::vector< float * > fDestinations
 
std::vector< std::shared_ptr< float > > fScalarFields
 
std::vector< std::shared_ptr< std::vector< float > > > fVectorFields
 
std::unique_ptr< ROOT::RNTupleWriterfWriter
 

#include <ROOT/ML/RBatchSink.hxx>

Inheritance diagram for ROOT::Experimental::Internal::ML::RNTupleBatchSink:
[legend]

Constructor & Destructor Documentation

◆ RNTupleBatchSink() [1/3]

ROOT::Experimental::Internal::ML::RNTupleBatchSink::RNTupleBatchSink ( std::string_view dataset_name,
std::string_view filename,
std::vector< RColumnLayout > layout )

Definition at line 79 of file RBatchSink.cxx.

◆ RNTupleBatchSink() [2/3]

ROOT::Experimental::Internal::ML::RNTupleBatchSink::RNTupleBatchSink ( const RNTupleBatchSink & )
delete

◆ RNTupleBatchSink() [3/3]

ROOT::Experimental::Internal::ML::RNTupleBatchSink::RNTupleBatchSink ( RNTupleBatchSink && )
delete

◆ ~RNTupleBatchSink()

ROOT::Experimental::Internal::ML::RNTupleBatchSink::~RNTupleBatchSink ( )
overridedefault

Member Function Documentation

◆ Commit()

void ROOT::Experimental::Internal::ML::RNTupleBatchSink::Commit ( )
overridevirtual

Flush everything to disk once after the last batch.

Implements ROOT::Experimental::Internal::ML::RBatchSink.

Definition at line 111 of file RBatchSink.cxx.

◆ FillBatch()

void ROOT::Experimental::Internal::ML::RBatchSink::FillBatch ( const RFlat2DMatrix & batch)
inherited

Write every row of batch.

Definition at line 25 of file RBatchSink.cxx.

◆ FillRow()

void ROOT::Experimental::Internal::ML::RNTupleBatchSink::FillRow ( const float * row)
overridevirtual

Copy one row of fRowWidth floats into the writer's buffers and write the entry.

Implements ROOT::Experimental::Internal::ML::RBatchSink.

Definition at line 104 of file RBatchSink.cxx.

◆ operator=() [1/2]

RNTupleBatchSink & ROOT::Experimental::Internal::ML::RNTupleBatchSink::operator= ( const RNTupleBatchSink & )
delete

◆ operator=() [2/2]

RNTupleBatchSink & ROOT::Experimental::Internal::ML::RNTupleBatchSink::operator= ( RNTupleBatchSink && )
delete

Member Data Documentation

◆ fDestinations

std::vector<float *> ROOT::Experimental::Internal::ML::RNTupleBatchSink::fDestinations
private

Definition at line 103 of file RBatchSink.hxx.

◆ fLayout

std::vector<RColumnLayout> ROOT::Experimental::Internal::ML::RBatchSink::fLayout
protectedinherited

Definition at line 52 of file RBatchSink.hxx.

◆ fRowWidth

std::size_t ROOT::Experimental::Internal::ML::RBatchSink::fRowWidth {}
protectedinherited

Definition at line 53 of file RBatchSink.hxx.

◆ fScalarFields

std::vector<std::shared_ptr<float> > ROOT::Experimental::Internal::ML::RNTupleBatchSink::fScalarFields
private

Definition at line 101 of file RBatchSink.hxx.

◆ fVectorFields

std::vector<std::shared_ptr<std::vector<float> > > ROOT::Experimental::Internal::ML::RNTupleBatchSink::fVectorFields
private

Definition at line 102 of file RBatchSink.hxx.

◆ fWriter

std::unique_ptr<ROOT::RNTupleWriter> ROOT::Experimental::Internal::ML::RNTupleBatchSink::fWriter
private

Definition at line 104 of file RBatchSink.hxx.

Libraries for ROOT::Experimental::Internal::ML::RNTupleBatchSink:

The documentation for this class was generated from the following files: