pynbody.kdtree#
Efficient 3D KDTree implementation for fast geometrical calculations such as neighbour lists and smoothing lengths.
As well as the smoothing operations built on it – sph_mean(),
sph_dispersion(), sph_divergence() and
sph_curl() – the tree can hand neighbour pairs back to python,
so that pairwise SPH operations pynbody does not itself provide can be written
without a python-level loop over particles. See pair_reduce()
and pair_blocks(), and buffered_kernel() for driving the
former from a compiled per-pair kernel.
Functions
|
Adapt a pair kernel that writes into output arrays for |
Classes
|
KDTree can be used for smoothing, interpolating and geometrical queries. |
Modules
KDTree module for pynbody |