Open3D (C++ API)
0.18.0+252c867
|
Functions | |
template<class T , class TIndex , class OUTPUT_ALLOCATOR > | |
void | FixedRadiusSearchCPU (int64_t *query_neighbors_row_splits, const size_t num_points, const T *const points, const size_t num_queries, const T *const queries, const T radius, const size_t points_row_splits_size, const int64_t *const points_row_splits, const size_t queries_row_splits_size, const int64_t *const queries_row_splits, const uint32_t *const hash_table_splits, const size_t hash_table_cell_splits_size, const uint32_t *const hash_table_cell_splits, const uint32_t *const hash_table_index, const Metric metric, const bool ignore_query_point, const bool return_distances, OUTPUT_ALLOCATOR &output_allocator) |
template<class T , class TIndex > | |
std::unique_ptr< NanoFlannIndexHolderBase > | BuildKdTree (size_t num_points, const T *const points, size_t dimension, const Metric metric) |
template<class T , class TIndex , class OUTPUT_ALLOCATOR > | |
void | KnnSearchCPU (NanoFlannIndexHolderBase *holder, int64_t *query_neighbors_row_splits, size_t num_points, const T *const points, size_t num_queries, const T *const queries, const size_t dimension, int knn, const Metric metric, bool ignore_query_point, bool return_distances, OUTPUT_ALLOCATOR &output_allocator) |
template<class T , class TIndex , class OUTPUT_ALLOCATOR > | |
void | RadiusSearchCPU (NanoFlannIndexHolderBase *holder, int64_t *query_neighbors_row_splits, size_t num_points, const T *const points, size_t num_queries, const T *const queries, const size_t dimension, const T *const radii, const Metric metric, bool ignore_query_point, bool return_distances, bool normalize_distances, bool sort, OUTPUT_ALLOCATOR &output_allocator) |
template<class T , class TIndex , class OUTPUT_ALLOCATOR > | |
void | HybridSearchCPU (NanoFlannIndexHolderBase *holder, size_t num_points, const T *const points, size_t num_queries, const T *const queries, const size_t dimension, const T radius, const int max_knn, const Metric metric, bool ignore_query_point, bool return_distances, OUTPUT_ALLOCATOR &output_allocator) |
std::unique_ptr<NanoFlannIndexHolderBase> open3d::core::nns::impl::BuildKdTree | ( | size_t | num_points, |
const T *const | points, | ||
size_t | dimension, | ||
const Metric | metric | ||
) |
Build KD Tree. This function build a KDTree for given dataset points.
T | Floating-point data type for the point positions. |
num_points | The number of points. |
points | Array with the point positions. |
dimension | The dimension of points. |
metric | Onf of L1, L2. Defines the distance metric for the search |
void open3d::core::nns::impl::FixedRadiusSearchCPU | ( | int64_t * | query_neighbors_row_splits, |
const size_t | num_points, | ||
const T *const | points, | ||
const size_t | num_queries, | ||
const T *const | queries, | ||
const T | radius, | ||
const size_t | points_row_splits_size, | ||
const int64_t *const | points_row_splits, | ||
const size_t | queries_row_splits_size, | ||
const int64_t *const | queries_row_splits, | ||
const uint32_t *const | hash_table_splits, | ||
const size_t | hash_table_cell_splits_size, | ||
const uint32_t *const | hash_table_cell_splits, | ||
const uint32_t *const | hash_table_index, | ||
const Metric | metric, | ||
const bool | ignore_query_point, | ||
const bool | return_distances, | ||
OUTPUT_ALLOCATOR & | output_allocator | ||
) |
Fixed radius search. This function computes a list of neighbor indices for each query point. The lists are stored linearly and an exclusive prefix sum defines the start and end of list in the array. In addition the function optionally can return the distances for each neighbor in the same format as the indices to the neighbors.
T | Floating-point data type for the point positions. |
OUTPUT_ALLOCATOR | Type of the output_allocator. See output_allocator for more information. |
query_neighbors_row_splits | This is the output pointer for the prefix sum. The length of this array is num_queries + 1. |
num_points | The number of points. |
points | Array with the 3D point positions. This must be the array that was used for building the spatial hash table. |
num_queries | The number of query points. |
queries | Array with the 3D query positions. This may be the same array as points . |
radius | The search radius. |
points_row_splits_size | The size of the points_row_splits array. The size of the array is batch_size+1. |
points_row_splits | Defines the start and end of the points in each batch item. The size of the array is batch_size+1. If there is only 1 batch item then this array is [0, num_points] |
queries_row_splits_size | The size of the queries_row_splits array. The size of the array is batch_size+1. |
queries_row_splits | Defines the start and end of the queries in each batch item. The size of the array is batch_size+1. If there is only 1 batch item then this array is [0, num_queries] |
hash_table_splits | Array defining the start and end the hash table for each batch item. This is [0, number of cells] if there is only 1 batch item or [0, hash_table_cell_splits_size-1] which is the same. |
hash_table_cell_splits_size | This is the length of the hash_table_cell_splits array. |
hash_table_cell_splits | This is an output of the function BuildSpatialHashTableCPU. The row splits array describing the start and end of each cell. |
hash_table_index | This is an output of the function BuildSpatialHashTableCPU. This is array storing the values of the hash table, which are the indices to the points. The size of the array must be equal to the number of points. |
metric | One of L1, L2, Linf. Defines the distance metric for the search. |
ignore_query_point | If true then points with the same position as the query point will be ignored. |
return_distances | If true then this function will return the distances for each neighbor to its query point in the same format as the indices. Note that for the L2 metric the squared distances will be returned!! |
output_allocator | An object that implements functions for allocating the output arrays. The object must implement functions AllocIndices(int64_t** ptr, size_t size) and AllocDistances(T** ptr, size_t size). Both functions should allocate memory and return a pointer to that memory in ptr. Argument size specifies the size of the array as the number of elements. Both functions must accept the argument size==0. In this case ptr does not need to be set. |
void open3d::core::nns::impl::HybridSearchCPU | ( | NanoFlannIndexHolderBase * | holder, |
size_t | num_points, | ||
const T *const | points, | ||
size_t | num_queries, | ||
const T *const | queries, | ||
const size_t | dimension, | ||
const T | radius, | ||
const int | max_knn, | ||
const Metric | metric, | ||
bool | ignore_query_point, | ||
bool | return_distances, | ||
OUTPUT_ALLOCATOR & | output_allocator | ||
) |
Hybrid search. This function computes a list of neighbor indices for each query point. The lists are stored linearly and an exclusive prefix sum defines the start and end of each list in the array. In addition the function optionally can return the distances for each neighbor in the same format as the indices to the neighbors.
T | Floating-point data type for the point positions. |
OUTPUT_ALLOCATOR | Type of the output_allocator. See output_allocator for more information. |
holder | The pointer that point to NanFlannIndexHolder that is built with BuildKdTree function. |
num_points | The number of points. |
points | Array with the point positions. This may be the same array as queries . |
num_queries | The number of query points. |
queries | Array with the query positions. This may be the same array as points . |
dimension | The dimension of points and queries . |
radius | The radius value that defines the neighbors region. |
max_knn | The maximum number of neighbors to search. |
metric | One of L1, L2. Defines the distance metric for the search. |
ignore_query_point | If true then points with the same position as the query point will be ignored. |
return_distances | If true then this function will return the distances for each neighbor to its query point in the same format as the indices. Note that for the L2 metric the squared distances will be returned!! |
output_allocator | An object that implements functions for allocating the output arrays. The object must implement functions AllocIndices(int32_t** ptr, size_t size) and AllocDistances(T** ptr, size_t size). Both functions should allocate memory and return a pointer to that memory in ptr. Argument size specifies the size of the array as the number of elements. Both functions must accept the argument size==0. In this case ptr does not need to be set. |
void open3d::core::nns::impl::KnnSearchCPU | ( | NanoFlannIndexHolderBase * | holder, |
int64_t * | query_neighbors_row_splits, | ||
size_t | num_points, | ||
const T *const | points, | ||
size_t | num_queries, | ||
const T *const | queries, | ||
const size_t | dimension, | ||
int | knn, | ||
const Metric | metric, | ||
bool | ignore_query_point, | ||
bool | return_distances, | ||
OUTPUT_ALLOCATOR & | output_allocator | ||
) |
KNN search. This function computes a list of neighbor indices for each query point. The lists are stored linearly and an exclusive prefix sum defines the start and end of each list in the array. In addition the function optionally can return the distances for each neighbor in the same format as the indices to the neighbors.
T | Floating-point data type for the point positions. |
OUTPUT_ALLOCATOR | Type of the output_allocator. See output_allocator for more information. |
holder | The pointer that point to NanFlannIndexHolder that is built with BuildKdTree function. |
query_neighbors_row_splits | This is the output pointer for the prefix sum. The length of this array is num_queries + 1. |
num_points | The number of points. |
points | Array with the point positions. This may be the same array as queries . |
num_queries | The number of query points. |
queries | Array with the query positions. This may be the same array as points . |
dimension | The dimension of points and queries . |
knn | The number of neighbors to search. |
metric | One of L1, L2. Defines the distance metric for the search. |
ignore_query_point | If true then points with the same position as the query point will be ignored. |
return_distances | If true then this function will return the distances for each neighbor to its query point in the same format as the indices. Note that for the L2 metric the squared distances will be returned!! |
output_allocator | An object that implements functions for allocating the output arrays. The object must implement functions AllocIndices(int32_t** ptr, size_t size) and AllocDistances(T** ptr, size_t size). Both functions should allocate memory and return a pointer to that memory in ptr. Argument size specifies the size of the array as the number of elements. Both functions must accept the argument size==0. In this case ptr does not need to be set. |
void open3d::core::nns::impl::RadiusSearchCPU | ( | NanoFlannIndexHolderBase * | holder, |
int64_t * | query_neighbors_row_splits, | ||
size_t | num_points, | ||
const T *const | points, | ||
size_t | num_queries, | ||
const T *const | queries, | ||
const size_t | dimension, | ||
const T *const | radii, | ||
const Metric | metric, | ||
bool | ignore_query_point, | ||
bool | return_distances, | ||
bool | normalize_distances, | ||
bool | sort, | ||
OUTPUT_ALLOCATOR & | output_allocator | ||
) |
Radius search. This function computes a list of neighbor indices for each query point. The lists are stored linearly and an exclusive prefix sum defines the start and end of each list in the array. In addition the function optionally can return the distances for each neighbor in the same format as the indices to the neighbors.
T | Floating-point data type for the point positions. |
OUTPUT_ALLOCATOR | Type of the output_allocator. See output_allocator for more information. |
holder | The pointer that point to NanFlannIndexHolder that is built with BuildKdTree function. |
query_neighbors_row_splits | This is the output pointer for the prefix sum. The length of this array is num_queries + 1. |
num_points | The number of points. |
points | Array with the point positions. This may be the same array as queries . |
num_queries | The number of query points. |
queries | Array with the query positions. This may be the same array as points . |
dimension | The dimension of points and queries . |
radii | A vector of search radii with length num_queries . |
metric | One of L1, L2. Defines the distance metric for the search. |
ignore_query_point | If true then points with the same position as the query point will be ignored. |
return_distances | If true then this function will return the distances for each neighbor to its query point in the same format as the indices. Note that for the L2 metric the squared distances will be returned!! |
normalize_distances | If true then the returned distances are normalized in the range [0,1]. Note that for L2 the normalized distance is squared. |
sort | If true then sort the resulting indices and distances in ascending order of distances. |
output_allocator | An object that implements functions for allocating the output arrays. The object must implement functions AllocIndices(int32_t** ptr, size_t size) and AllocDistances(T** ptr, size_t size). Both functions should allocate memory and return a pointer to that memory in ptr. Argument size specifies the size of the array as the number of elements. Both functions must accept the argument size==0. In this case ptr does not need to be set. |