PicoTree v1.0.0
is released to celebrate a change in code style (a change that will never happen again...). Besides having an updated style, the biggest change to the kd_tree
has been made to its construction parameters. The SplittingRule
class template parameter has been replaced by a constructor parameter. Additionally, there are two new parameters that help influence how the kd_tree
is constructed. The complete set of parameters is now as follows:
splitter_rule_t
can be one ofmedian_max_side
,midpoint_max_side
, orsliding_midpoint_max_side
.splitter_start_bounds_t
can be one ofbounds_from_space
orbounds_t
. The latter allows setting a custom or precomputed input bounds.splitter_stop_condition_t
can be one ofmax_leaf_size_t
ormax_leaf_depth_t
.
C++ changes:
- Added extra parameters to the
kd_tree
constructor (see above).- The
kd_tree_creation.cpp
example has been updated to reflect the new changes.
- The
- Added the
leaf_ranges
method to thekd_tree
. It returns a range of indices per leaf. - Metrics with the
topological_space_tag
now supportsearch_box
queries.- Support for metrics with a
topological_space_tag
is now identical to those with aeuclidean_space_tag
.
- Support for metrics with a
- Simplified the interface for Euclidean and topological metrics (reduced interface function requirements).
- See the new
kd_tree_custom_metric.cpp
example for more details.
- See the new
- The input range for all S1 distance functions has been updated from
[-pi...+pi]
to[0...1]
.- This simplifies implementation details, but also the use of S1 and related spaces.
- Added the
<pico_tree/distance.hpp>
header that contains various distance functions.- It was mostly added to support creating custom metrics.
- Added
metric_lninf
supporting negative infinity. - Renamed
metric_linf
tometric_lpinf
(positive infinity). - Renamed
MatWrapper
toopencv_mat_map
.opencv_mat_map
adds support for interfacing with aconst cv::Mat
on top of the previous non-const support.
- Renamed
dynamic_size
todynamic_extent
to avoid name collisions (withsize
). pico_toolshed
classes have been moved inside thepico_tree
namespace.- From Camels to Snakes in the year of the snake.
- Fix:
metric_se2_squared
called the incorrect distance function. - Fix:
space_traits<dynamic_space>
definedsdim
incorrectly.
Python changes:
- Reduced the compile time of the Python module by 40%.
- Added the
save_kd_tree
andload_kd_tree
functions to the Python interface.- The
kd_tree.py
example has been updated to demonstrate the new functionality.
- The
- Renamed
LInf
toLPInf
(positive infinity). - Replaced several
std::runtime_error
exceptions bystd::invalid_argument
. - Updated the minimum Python version to 3.10.