Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TMVA::Experimental::Internal Namespace Reference

Classes

struct  and_types
 Type checking for all types of a parameter pack, e.g., used in combination with std::is_convertible. More...
 
struct  and_types< T0, Ts... >
 
class  ComputeHelper
 Compute helper. More...
 
class  ComputeHelper< std::index_sequence< N... >, T, F >
 
class  RBatchGenerator
 
class  RBatchLoader
 
class  RChunkLoader
 
class  RChunkLoaderFunctor
 
struct  XMLConfig
 Container for information extracted from TMVA XML config. More...
 

Enumerations

enum  AnalysisType : unsigned int { Undefined = 0 , Classification , Regression , Multiclass }
 Internal definition of analysis types. More...
 

Functions

template<typename U , typename V >
std::size_t ComputeGlobalIndex (const U &strides, const V &idx)
 Compute global index from indices.
 
template<typename T >
ComputeIndicesFromGlobalIndex (const T &shape, MemoryLayout layout, const typename T::value_type idx)
 Compute indices from global index.
 
template<typename T >
std::vector< std::size_t > ComputeStridesFromShape (const T &shape, MemoryLayout layout)
 Compute strides from shape vector.
 
template<typename T >
std::size_t GetSizeFromShape (const T &shape)
 Get size of tensor from shape vector.
 
XMLConfig ParseXMLConfig (const std::string &filename)
 Parse TMVA XML config.
 
template<typename T >
void RecursiveCopy (const T &here, T &there, const std::vector< std::size_t > &mins, const std::vector< std::size_t > &maxs, std::vector< std::size_t > idx, std::size_t active)
 Copy slice of a tensor recursively from here to there.
 

Enumeration Type Documentation

◆ AnalysisType

Internal definition of analysis types.

Enumerator
Undefined 
Classification 
Regression 
Multiclass 

Definition at line 19 of file RReader.hxx.

Function Documentation

◆ ComputeGlobalIndex()

template<typename U , typename V >
std::size_t TMVA::Experimental::Internal::ComputeGlobalIndex ( const U &  strides,
const V &  idx 
)
inline

Compute global index from indices.

Parameters
[in]stridesStrides vector
[in]idxIndice vector
Returns
Global index

Definition at line 99 of file RTensor.hxx.

◆ ComputeIndicesFromGlobalIndex()

template<typename T >
T TMVA::Experimental::Internal::ComputeIndicesFromGlobalIndex ( const T &  shape,
MemoryLayout  layout,
const typename T::value_type  idx 
)
inline

Compute indices from global index.

Parameters
[in]shapeShape vector
[in]idxGlobal index
[in]layoutMemory layout
Returns
Indice vector

Definition at line 81 of file RTensor.hxx.

◆ ComputeStridesFromShape()

template<typename T >
std::vector< std::size_t > TMVA::Experimental::Internal::ComputeStridesFromShape ( const T &  shape,
MemoryLayout  layout 
)
inline

Compute strides from shape vector.

Parameters
[in]shapeShape vector
[in]layoutMemory layout
Returns
Size of contiguous memory

This information is needed for the multi-dimensional indexing. See here: https://en.wikipedia.org/wiki/Row-_and_column-major_order https://docs.scipy.org/doc/numpy/reference/generated/numpy.ndarray.strides.html

Definition at line 47 of file RTensor.hxx.

◆ GetSizeFromShape()

template<typename T >
std::size_t TMVA::Experimental::Internal::GetSizeFromShape ( const T &  shape)
inline

Get size of tensor from shape vector.

Parameters
[in]shapeShape vector
Returns
Size of contiguous memory

Definition at line 28 of file RTensor.hxx.

◆ ParseXMLConfig()

XMLConfig TMVA::Experimental::Internal::ParseXMLConfig ( const std::string &  filename)
inline

Parse TMVA XML config.

Definition at line 42 of file RReader.hxx.

◆ RecursiveCopy()

template<typename T >
void TMVA::Experimental::Internal::RecursiveCopy ( const T &  here,
T &  there,
const std::vector< std::size_t > &  mins,
const std::vector< std::size_t > &  maxs,
std::vector< std::size_t >  idx,
std::size_t  active 
)

Copy slice of a tensor recursively from here to there.

Parameters
[in]hereSource tensor
[in]thereTarget tensor (slice of source tensor)
[in]minsMinimum of indices for each dimension
[in]maxsMaximum of indices for each dimension
[in]idxCurrent indices
[in]activeActive index needed to stop the recursion

Copy the content of a slice of a tensor from source to target. This is done by recursively iterating over the ranges of the slice for each dimension.

Definition at line 129 of file RTensor.hxx.