table of contents
mlpack_kfn(1) | User Commands | mlpack_kfn(1) |
NAME¶
mlpack_kfn - k-furthest-neighbors search
SYNOPSIS¶
mlpack_kfn [-a string] [-e double] [-m unknown] [-k int] [-l int] [-p double] [-q unknown] [-R bool] [-r unknown] [-s int] [-t string] [-D unknown] [-T unknown] [-V bool] [-d unknown] [-n unknown] [-M unknown] [-h -v]
DESCRIPTION¶
This program will calculate the k-furthest-neighbors of a set of points. You may specify a separate set of reference points and query points, or just a reference set which will be used as both the reference and query set.
For example, the following will calculate the 5 furthest neighbors of eachpoint in 'input.csv' and store the distances in 'distances.csv' and the neighbors in 'neighbors.csv':
$ mlpack_kfn --k 5 --reference_file input.csv --distances_file distances.csv --neighbors_file neighbors.csv
The output files are organized such that row i and column j in the neighbors output matrix corresponds to the index of the point in the reference set which is the j'th furthest neighbor from the point in the query set with index i. Row i and column j in the distances output file corresponds to the distance between those two points.
OPTIONAL INPUT OPTIONS¶
- --algorithm (-a) [string]
- Type of neighbor search: 'naive', 'single_tree', 'dual_tree', 'greedy'. Default value 'dual_tree'.
- --epsilon (-e) [double]
- If specified, will do approximate furthest neighbor search with given relative error. Must be in the range [0,1). Default value 0.
- --help (-h) [bool]
- Default help info.
- --info [string]
- Print help on a specific option. Default value ''.
- --input_model_file (-m) [unknown]
- Pre-trained kFN model.
- --k (-k) [int]
- Number of furthest neighbors to find. Default value 0.
- --leaf_size (-l) [int]
- Leaf size for tree building (used for kd-trees, vp trees, random projection trees, UB trees, R trees, R* trees, X trees, Hilbert R trees, R+ trees, R++ trees, and octrees). Default value 20.
- --percentage (-p) [double]
- If specified, will do approximate furthest neighbor search. Must be in the range (0,1] (decimal form). Resultant neighbors will be at least (p*100) % of the distance as the true furthest neighbor. Default value 1.
- --query_file (-q) [unknown]
- Matrix containing query points (optional).
- --random_basis (-R) [bool]
- Before tree-building, project the data onto a random orthogonal basis.
- --reference_file (-r) [unknown]
- Matrix containing the reference dataset.
- --seed (-s) [int]
- Random seed (if 0, std::time(NULL) is used). Default value 0.
- --tree_type (-t) [string]
- Type of tree to use: 'kd', 'vp', 'rp', 'max-rp', 'ub', 'cover', 'r', 'r-star', 'x', 'ball', 'hilbert-r', 'r-plus', 'r-plus-plus', 'oct'. Default value 'kd'.
- --true_distances_file (-D) [unknown]
- Matrix of true distances to compute the effective error (average relative error) (it is printed when -v is specified).
- --true_neighbors_file (-T) [unknown]
- Matrix of true neighbors to compute the recall (it is printed when -v is specified).
- --verbose (-v) [bool]
- Display informational messages and the full list of parameters and timers at the end of execution.
- --version (-V) [bool]
- Display the version of mlpack.
OPTIONAL OUTPUT OPTIONS¶
- --distances_file (-d) [unknown]
- Matrix to output distances into.
- --neighbors_file (-n) [unknown]
- Matrix to output neighbors into.
- --output_model_file (-M) [unknown]
- If specified, the kFN model will be output here.
ADDITIONAL INFORMATION¶
For further information, including relevant papers, citations, and theory, consult the documentation found at http://www.mlpack.org or included with your distribution of mlpack.
23 September 2024 | mlpack-4.5.0 |