The kD trees in LALInference are composed of cells.
Each cell represents a rectangular region in parameter space, defined by \(\mathrm{lowerLeft} <= x <= \mathrm{upperRight}\). It also contains two sub-cells, each of which represents rectangular regions of half the size. The dimension along which a cell at a particular level in the tree is split in half is given by its level (mod the dimension of the space).
Each cell contains some number (which may be zero) of points. Periodically, the cell will compute the mean and covariance of its points, and the eigenvectors of the covariance matrix (principal axes) of an ellipse fitting the the points. It will also compute the (tight) bounds of a box enclosing the points in a coordinate system aligned with the principal axes. When this has been done, the eigenFrameStale
element will be set to zero. If points are subsequently added to the cell, the eigenFrameStale
flag will be set to a non-zero value until the next re-computation of the principal axes.
Definition at line 915 of file LALInference.h.
Data Fields | |
size_t | npts |
size_t | ptsSize |
Stores the number of tree points that lie in the cell. More... | |
size_t | dim |
Size of the pts buffer. More... | |
REAL8 ** | pts |
Dimension of the system. More... | |
REAL8 * | ptsMean |
REAL8 * | lowerLeft |
Mean of pts. More... | |
REAL8 * | upperRight |
Lower left (i.e. More... | |
REAL8 ** | ptsCov |
Upper right (i.e. More... | |
REAL8 ** | ptsCovEigenVects |
dim-by-dim covariance matrix. More... | |
REAL8 * | eigenMin |
Eigenvectors of the covariance matrix: [i][j] is the jth component of the ith eigenvector. More... | |
REAL8 * | eigenMax |
Minimum coordinates of points in the eigen-frame. More... | |
int | eigenFrameStale |
Maximum coordinates of points in the eigen-frame. More... | |
struct tagLALInferenceKDTree * | left |
== 1 when the mean, covariance, and eigenvectors are out of date (i.e. More... | |
struct tagLALInferenceKDTree * | right |
Left (i.e. More... | |
size_t LALInferenceKDTree::npts |
Definition at line 916 of file LALInference.h.
size_t LALInferenceKDTree::ptsSize |
Stores the number of tree points that lie in the cell.
Definition at line 917 of file LALInference.h.
size_t LALInferenceKDTree::dim |
Size of the pts buffer.
Definition at line 918 of file LALInference.h.
REAL8** LALInferenceKDTree::pts |
Dimension of the system.
Definition at line 919 of file LALInference.h.
REAL8* LALInferenceKDTree::ptsMean |
Definition at line 920 of file LALInference.h.
REAL8* LALInferenceKDTree::lowerLeft |
Mean of pts.
Definition at line 921 of file LALInference.h.
REAL8* LALInferenceKDTree::upperRight |
Lower left (i.e.
coordinate minimum) bound; length is ndim from LALInferenceKDTree.
Definition at line 923 of file LALInference.h.
REAL8** LALInferenceKDTree::ptsCov |
REAL8** LALInferenceKDTree::ptsCovEigenVects |
dim-by-dim covariance matrix.
Definition at line 925 of file LALInference.h.
REAL8* LALInferenceKDTree::eigenMin |
Eigenvectors of the covariance matrix: [i][j] is the jth component of the ith eigenvector.
Definition at line 928 of file LALInference.h.
REAL8* LALInferenceKDTree::eigenMax |
Minimum coordinates of points in the eigen-frame.
Definition at line 929 of file LALInference.h.
int LALInferenceKDTree::eigenFrameStale |
Maximum coordinates of points in the eigen-frame.
Definition at line 930 of file LALInference.h.
struct tagLALInferenceKDTree* LALInferenceKDTree::left |
== 1 when the mean, covariance, and eigenvectors are out of date (i.e.
more points added).
Definition at line 933 of file LALInference.h.
struct tagLALInferenceKDTree* LALInferenceKDTree::right |
Left (i.e.
lower-coordinate) sub-tree, may be NULL if empty.
Definition at line 936 of file LALInference.h.