Nearest-Neighbor (NN) search with KD-trees C++ library
This project builds and defines the build2 package for nanoflann, a C++11 header-only library for Nearest Neighbor (NN) search with KD-trees.
Usage
Make sure to add the stable section of the cppget.org
repository to your project's repositories.manifest
to be able to fetch the package.
:
role: prerequisite
location: https://pkg.cppget.org/1/stable
# trust: ...
If the stable section of cppget.org
is not an option then add this Git repository itself instead as a prerequisite.
:
role: prerequisite
location: https://github.com/build2-packaging/nanoflann.git
Tests
Examples
Builds
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-clang_15.0-O3 |
timestamp |
2024-05-08 17:06:24 UTC (08:36:55 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_16_libc++-static_O3 |
timestamp |
2024-05-08 15:31:08 UTC (10:12:10 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_16_libc++-O3 |
timestamp |
2024-05-08 15:30:36 UTC (10:12:43 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_16-static_O3 |
timestamp |
2024-05-08 15:30:36 UTC (10:12:43 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_16_libc++ |
timestamp |
2024-05-08 15:30:05 UTC (10:13:14 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_16-O3 |
timestamp |
2024-05-08 15:29:32 UTC (10:13:47 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_16 |
timestamp |
2024-05-08 15:29:00 UTC (10:14:19 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-gcc_13_homebrew-static_O3 |
timestamp |
2024-05-08 14:45:33 UTC (10:57:45 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-gcc_13_homebrew-O3 |
timestamp |
2024-05-08 14:44:54 UTC (10:58:24 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-gcc_13_homebrew |
timestamp |
2024-05-08 14:44:18 UTC (10:59:01 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_16.0_libc++-static_O3 |
timestamp |
2024-05-08 14:31:20 UTC (11:11:59 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_16.0_libc++ |
timestamp |
2024-05-08 14:27:58 UTC (11:15:20 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_16.0-static_O3 |
timestamp |
2024-05-08 14:27:24 UTC (11:15:55 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_16.0_libc++-O3 |
timestamp |
2024-05-08 14:27:21 UTC (11:15:57 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_16.0-O3 |
timestamp |
2024-05-08 14:26:51 UTC (11:16:28 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_16.0 |
timestamp |
2024-05-08 14:26:45 UTC (11:16:34 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_fedora_38-gcc_13-bindist |
timestamp |
2024-05-08 14:14:43 UTC (11:28:36 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_fedora_37-gcc_12.2-bindist |
timestamp |
2024-05-08 13:17:18 UTC (12:26:00 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-w64-mingw32 |
tgt config |
windows_10-gcc_12.2_mingw_w64-O2 |
timestamp |
2024-05-08 13:07:32 UTC (12:35:47 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-w64-mingw32 |
tgt config |
windows_10-gcc_12.2_mingw_w64 |
timestamp |
2024-05-08 13:07:18 UTC (12:36:01 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-w64-mingw32 |
tgt config |
windows_10-gcc_12.2_mingw_w64-static_O2 |
timestamp |
2024-05-08 13:07:08 UTC (12:36:10 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-gcc_13.1-O3 |
timestamp |
2024-05-08 13:07:05 UTC (12:36:14 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-gcc_12-bindist |
timestamp |
2024-05-08 13:06:59 UTC (12:36:19 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_15_libc++ |
timestamp |
2024-05-08 13:06:50 UTC (12:36:29 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-clang_15 |
timestamp |
2024-05-08 13:06:46 UTC (12:36:33 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-gcc_13.1-ndebug_O3 |
timestamp |
2024-05-08 13:06:40 UTC (12:36:39 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-freebsd13.2 |
tgt config |
freebsd_13-clang_14.0 |
timestamp |
2024-05-08 13:06:34 UTC (12:36:44 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-gcc_13.1-static_O3 |
timestamp |
2024-05-08 13:06:34 UTC (12:36:45 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-freebsd13.2 |
tgt config |
freebsd_13-clang_14.0-O3 |
timestamp |
2024-05-08 13:05:19 UTC (12:37:59 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-gcc_13.1 |
timestamp |
2024-05-08 13:05:06 UTC (12:38:12 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_15.0_libc++ |
timestamp |
2024-05-08 13:03:36 UTC (12:39:43 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-freebsd12.4 |
tgt config |
freebsd_12-clang_13.0 |
timestamp |
2024-05-08 13:03:18 UTC (12:40:01 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_11-gcc_12.1 |
timestamp |
2024-05-08 13:02:29 UTC (12:40:50 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-linux-gnu |
tgt config |
linux_debian_12-clang_15.0 |
timestamp |
2024-05-08 12:57:59 UTC (12:45:20 hours ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-gcc_13-static_O3 |
timestamp |
2024-05-08 12:06:03 UTC (13:37:16 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-gcc_13-ndebug_O3 |
timestamp |
2024-05-08 12:05:40 UTC (13:37:38 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-gcc_13 |
timestamp |
2024-05-08 12:05:31 UTC (13:37:47 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_12-gcc_13-O3 |
timestamp |
2024-05-08 12:05:08 UTC (13:38:11 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-clang_16.0_llvm_msvc_17.6 |
timestamp |
2024-05-08 11:21:46 UTC (14:21:32 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-clang_16.0_llvm_msvc_17.6-O2 |
timestamp |
2024-05-08 11:20:40 UTC (14:22:39 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-clang_16.0_llvm_msvc_17.6-static_O2 |
timestamp |
2024-05-08 11:19:17 UTC (14:24:02 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-msvc_17.6-O2 |
timestamp |
2024-05-08 11:07:37 UTC (14:35:41 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-msvc_17.6 |
timestamp |
2024-05-08 11:07:24 UTC (14:35:55 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-msvc_17.6-static_O2 |
timestamp |
2024-05-08 11:05:01 UTC (14:38:18 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-clang_15.0_msvc_msvc_17.6 |
timestamp |
2024-05-08 11:04:44 UTC (14:38:34 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-microsoft-win32-msvc14.3 |
tgt config |
windows_10-msvc_17.5 |
timestamp |
2024-05-08 11:04:21 UTC (14:38:58 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
aarch64-linux-gnu |
tgt config |
linux_debian_11-gcc_12 |
timestamp |
2024-05-08 11:02:04 UTC (14:41:15 hours ago) |
result |
warning (test) | warning (test-installed) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-freebsd13.2 |
tgt config |
freebsd_13-clang_14.0-static_O3 |
timestamp |
2024-05-08 10:31:55 UTC (15:11:23 hours ago) |
result |
error (test) | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-clang_15.0-static_O3 |
timestamp |
2024-05-06 04:32:32 UTC (02 21:10:47 days ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-clang_15.0 |
timestamp |
2024-05-06 04:30:02 UTC (02 21:13:16 days ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-clang_14.0-static_O3 |
timestamp |
2024-05-06 01:34:42 UTC (03 00:08:37 days ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-clang_14.0-O3 |
timestamp |
2024-05-06 01:33:03 UTC (03 00:10:15 days ago) |
result |
success | log | rebuild |
toolchain |
public-0.16.0 |
target |
x86_64-apple-darwin22.5.0 |
tgt config |
macos_13-clang_14.0 |
timestamp |
2024-05-06 01:31:43 UTC (03 00:11:35 days ago) |
result |
success | log | rebuild |
Changes
nanoflann 1.5.4: Released Jan 10, 2024
- Fix outdated NANOFLANN_VERSION macro in header file
- Fix poll-allocator alignment problems
- Add NANOFLANN_USE_SYSTEM_GTEST option
- Look for Threads dependency in CMake config script
nanoflann 1.5.3: Released Dec 7, 2023
- Other changes:
- Save one redundant call to
computeMinMax()
in middleSplit_
(PR#220 by qq422216549).
This saves a lot of time, up to 20% faster in a benchmark with small (thousands) point clouds.
nanoflann 1.5.2: Released Nov 29, 2023
nanoflann 1.5.1: Released Nov 27, 2023
- API changes:
- Add new search method
rknnSearch()
for knn searches with a maximum radius.
- Add missing
SearchParameters
argument to KDTreeSingleIndexDynamicAdaptor_::knnSearch()
(PR#213 by ManosPapadakis95).
- Add missing method
KNNResultSet::empty()
for consistency with the other result sets.
- Other changes:
- Add GUI examples for each search type:
nanoflann_gui_example_R3_knn
nanoflann_gui_example_R3_radius
nanoflann_gui_example_R3_rknn
nanoflann 1.5.0: Released Jun 16, 2023
- API changes:
- Users of radius search should change their result placeholder type:
std::vector<std::pair<IndexType, DistanceType>>
=> std::vector<nanoflann::ResultItem<IndexType, DistanceType>>
. (See #166 for the motivation of this change).
- More concise auxiliary (internal) type name:
array_or_vector_selector
-> array_or_vector
.
- Remove obsolete parameter
nChecks_IGNORED
. Removed from SearchParams
constructor too, so that structure has been renamed SearchParameters
to
enforce users to update the code and avoid mistakes with the order of its
ctor parameters.
- Added method RadiusResultSet::empty()
- Template argument rename:
AccesorType
=> IndexType
(does not actually affect user code at all).
- Added concurrent tree building support, refer to
KDTreeSingleIndexAdaptorParams::n_thread_build
.
- Other changes:
- Macros to avoid conflicts with X11 symbols.
- Inline an auxiliary example function in case users want to use it and
include the file in multiple translation units (Closes #182).
- Move all benchmarking code, data, and scripts to its own repository to keep this repo as clean as possible.
- Fix "potentially uninitialized" GCC warning.
- Clarified, even more, in docs and examples, that L2 distances are squared distances.
- Removed the (with modern compilers) now useless
inline
keyword in class members.
- Add examples with GUI (requires mrpt-gui):
- nanoflann_gui_example_R3: Radius search on R³ Euclidean space.
- nanoflann_gui_example_bearings: NN search on non-Euclidean spaces.
- BUGFIXES:
- Avoid segfault if saving an empty index (Closes #205).
nanoflann 1.4.3: Released Jul 24, 2022
- Added flag SkipInitialBuildIndex to allow not wasting time building a tree when it will be loaded from a file later on (PR #171).
- Mark all constructors explicit, to avoid unintended creation of temporary objects (Issue #179).
- BUGFIX: avoid potential index out of bounds in KDTreeSingleIndexDynamicAdaptor (PR #173)
nanoflann 1.4.2: Released Jan 11, 2022
- Install pkg-config .pc file under lib directory (Closes #161).
- Integrate AppVeyor CI.
nanoflann 1.4.1: Released Jan 6, 2022
- Fix incorrect install directory for cmake target & config files.
- Do not install example binaries with
make install
.
- Provide working examples for cmake and pkgconfig under
examples/example_*
directories.
nanoflann 1.4.0: Released Jan 2, 2022
- nanoflann::KDTreeSingleIndexAdaptor() ctor now forwards additional parameters to the metric class, enabling custom dynamic metrics.
- Add and apply a
.clang-format
file (same one than used in MOLAorg/MOLA projects).
- Examples: clean up and code modernization.
- CMake variables prefixed now with
NANOFLANN_
for easier integration of nanoflann as a Git submodule.
- Fixes for IndexType which are not of integral types PR #154
- save/load API upgraded from C
FILE*
to C++ file streams (By Dominic Kempf, Heidelberg University, PR).
nanoflann 1.3.2: Released Nov 5, 2020
- Add optional argument for Eigen matrix layout commit.
- Throw exception on malloc failure PR #126.
- Respect GNUInstallDirs in CMake install rules PR #131.
nanoflann 1.3.1: Released Oct 11, 2019
nanoflann 1.3.0: Released Aug 28, 2018
- Instructions for
make install
for Linux and Windows (Closes #87).
- Fix all (?) MSVC conversion warnings (Closes: #95).
- Avoid need for _USE_MATH_DEFINES in MSVC (Closes: #96)
- Eigen::Matrix datasets: now uses std::cref() to store a reference to matrix.
- GSOC2017 contributions by Pranjal Kumar Rai:
- Support for dynamic datasets.
- Support for non-Euclidean spaces: SO(2), SO(3)
nanoflann 1.2.3: Released Dec 20, 2016
- Fixed: split plane now correctly chooses the dimensions with the largest span.
Should lead to more optimal trees.