int Int_t
Signed integer 4 bytes (int)
 
unsigned char UChar_t
Unsigned Character 1 byte (unsigned char)
 
unsigned int UInt_t
Unsigned integer 4 bytes (unsigned int)
 
#define ClassDefOverride(name, id)
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t index
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize id
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
 
TKDTree< Int_t, Double_t > TKDTreeID
 
TKDTreeIF * TKDTreeTestBuild()
 
TKDTree< Int_t, Float_t > TKDTreeIF
 
Class implementing a kd-tree.
 
Int_t GetLeft(Int_t inode) const
 
UChar_t GetNodeAxis(Int_t id) const
 
Int_t GetOffset()
cross node
 
Int_t GetTotalNodes() const
 
void FindPoint(Value *point, Index &index, Int_t &iter)
find the index of point works only if we keep fData pointers
 
void SetData(Index npoints, Index ndim, UInt_t bsize, Value **data)
Set the data array. See the constructor function comments for details.
 
Int_t GetCrossNode()
smallest terminal row
 
Int_t fCrossNode
! cross node - node that begins the last row (with terminal nodes only)
 
~TKDTree() override
Destructor By default, the original data is not owned by kd-tree and is not deleted with it.
 
void GetNodePointsIndexes(Int_t node, Int_t &first1, Int_t &last1, Int_t &first2, Int_t &last2) const
Return the indices of points in that node Indices are returned as the first and last value of the par...
 
Index * GetIndPoints()
offset in fIndPoints
 
Index * fIndPoints
! array of points indexes
 
Value * fValue
[fNNodes] nodes cutting value
 
Value * GetBoundaryExact(const Int_t node)
Get a boundary.
 
void FindBNodeA(Value *point, Value *delta, Int_t &inode)
find the smallest node covering the full range - start
 
Value * fRange
[fNDimm] range of data for each dimension
 
void UpdateRange(Index inode, Value *point, Value range, std::vector< Index > &res)
Internal recursive function with the implementation of range searches.
 
Index FindNode(const Value *point) const
returns the index of the terminal node to which point belongs (index in the fAxis,...
 
Int_t fNNodes
size of node array
 
Value ** fData
! data points
 
Value KOrdStat(Index ntotal, Value *a, Index k, Index *index) const
copy of the TMath::KOrdStat because I need an Index work array
 
Int_t fOffset
! offset in fIndPoints - if there are 2 rows, that contain terminal nodes fOffset returns the index i...
 
Value GetNodeValue(Int_t id) const
 
Value * GetBoundariesExact()
Get the boundaries.
 
UChar_t * fAxis
[fNNodes] nodes cutting axis
 
Int_t fDataOwner
! 0 - not owner, 2 - owner of the pointer array, 1 - owner of the whole 2-d array
 
Index fNDim
number of dimensions
 
void MakeBoundariesExact()
Build boundaries for each node.
 
void CookBoundaries(const Int_t node, Bool_t left)
define index of this terminal node
 
void MakeBoundaries(Value *range=nullptr)
Build boundaries for each node.
 
void UpdateNearestNeighbors(Index inode, const Value *point, Int_t kNN, Index *ind, Value *dist)
Update the nearest neighbors values by examining the node inode.
 
Int_t GetRight(Int_t inode) const
 
Int_t GetParent(Int_t inode) const
 
Double_t Distance(const Value *point, Index ind, Int_t type=2) const
Find the distance between point of the first argument and the point at index value ind Type argument ...
 
Index fBucketSize
size of the terminal nodes
 
Index * GetPointsIndexes(Int_t node) const
return the indices of the points in that terminal node for all the nodes except last,...
 
void Spread(Index ntotal, Value *a, Index *index, Value &min, Value &max) const
Calculate spread of the array a.
 
void Build()
Build the kd-tree.
 
void DistanceToNode(const Value *point, Index inode, Value &min, Value &max, Int_t type=2)
Find the minimal and maximal distance from a given point to a given node.
 
TKDTree()
Default constructor. Nothing is built.
 
Int_t fRowT0
! smallest terminal row - first row that contains terminal nodes
 
void SetOwner(Int_t owner)
 
void FindInRange(Value *point, Value range, std::vector< Index > &res)
Find all points in the sphere of a given radius "range" around the given point 1st argument - the poi...
 
Value * fBoundaries
! nodes boundaries
 
Bool_t IsTerminal(Index inode) const
 
Index GetNPointsNode(Int_t node) const
Get number of points in this node for all the terminal nodes except last, the size is fBucketSize for...
 
Value * GetBoundaries()
Get the boundaries.
 
Index fNDimm
dummy 2*fNDim
 
Value * GetBoundary(const Int_t node)
Get a boundary.
 
TKDTree< Index, Value > & operator=(const TKDTree< Index, Value > &)
 
Int_t fTotalNodes
total number of nodes (fNNodes + terminal nodes)
 
void FindNearestNeighbors(const Value *point, Int_t k, Index *ind, Value *dist)
Find kNN nearest neighbors to the point in the first argument Returns 1 on success,...
 
Index fNPoints
number of multidimensional points
 
kNN::Event describes point in input variable vector-space, with additional functionality like distanc...
 
Mother of all ROOT objects.