rosetta.numeric.kdtree
index
(built-in)

Bindings for numeric::kdtree namespace

 
Classes
       
builtins.object
CompareKDPoints
HyperRectangle
KDNode
KDPoint
KDPointList
KDPoint_MinDist
KDTree

 
class CompareKDPoints(builtins.object)
     Methods defined here:
__call__(...) from builtins.PyCapsule
__call__(self : rosetta.numeric.kdtree.CompareKDPoints, x : rosetta.numeric.kdtree.KDPoint, y : rosetta.numeric.kdtree.KDPoint) -> bool
__init__(...) from builtins.PyCapsule
__init__(*args, **kwargs)
Overloaded function.
 
1. __init__(rosetta.numeric.kdtree.CompareKDPoints) -> NoneType
 
2. __init__(self : rosetta.numeric.kdtree.CompareKDPoints, new_idx : int) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.

 
class HyperRectangle(builtins.object)
     Methods defined here:
__init__(...) from builtins.PyCapsule
__init__(*args, **kwargs)
Overloaded function.
 
1. __init__(rosetta.numeric.kdtree.HyperRectangle) -> NoneType
 
2. __init__(self : rosetta.numeric.kdtree.HyperRectangle, upper : rosetta.utility.vector1_double, lower : rosetta.utility.vector1_double) -> NoneType
 
3. __init__(self : rosetta.numeric.kdtree.HyperRectangle, pts : rosetta.utility.vector1_utility_vector1_double_std_allocator_double_t) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.
assign(...) from builtins.PyCapsule
assign(self : rosetta.numeric.kdtree.HyperRectangle, src : rosetta.numeric.kdtree.HyperRectangle) -> rosetta.numeric.kdtree.HyperRectangle
extend(...) from builtins.PyCapsule
extend(self : rosetta.numeric.kdtree.HyperRectangle, pt : rosetta.utility.vector1_double) -> NoneType
lower(...) from builtins.PyCapsule
lower(rosetta.numeric.kdtree.HyperRectangle) -> rosetta.utility.vector1_double
ndim(...) from builtins.PyCapsule
ndim(rosetta.numeric.kdtree.HyperRectangle) -> int
upper(...) from builtins.PyCapsule
upper(rosetta.numeric.kdtree.HyperRectangle) -> rosetta.utility.vector1_double

 
class KDNode(builtins.object)
     Methods defined here:
__init__(...) from builtins.PyCapsule
__init__(self : rosetta.numeric.kdtree.KDNode, tree : rosetta.numeric.kdtree.KDTree) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.
distance(...) from builtins.PyCapsule
distance(*args, **kwargs)
Overloaded function.
 
1. distance(rosetta.numeric.kdtree.KDNode) -> float
 
2. distance(self : rosetta.numeric.kdtree.KDNode, new_dist : float) -> NoneType
is_leaf(...) from builtins.PyCapsule
is_leaf(rosetta.numeric.kdtree.KDNode) -> bool
 
Returns true if this node has no children, false otherwise.
is_root(...) from builtins.PyCapsule
is_root(rosetta.numeric.kdtree.KDNode) -> bool
 
Returns true if this node has no parent, false otherwise.
left_child(...) from builtins.PyCapsule
left_child(*args, **kwargs)
Overloaded function.
 
1. left_child(rosetta.numeric.kdtree.KDNode) -> rosetta.numeric.kdtree.KDNode
 
Returns the left child of this KDNode in the tree,
 or NULL if there is no left child.
 
2. left_child(self : rosetta.numeric.kdtree.KDNode, new_left_child : rosetta.numeric.kdtree.KDNode) -> NoneType
 
Sets the left child for this node.
location(...) from builtins.PyCapsule
location(*args, **kwargs)
Overloaded function.
 
1. location(rosetta.numeric.kdtree.KDNode) -> rosetta.utility.vector1_double
 
Returns the location of this node in k-space.
 
2. location(self : rosetta.numeric.kdtree.KDNode, new_location : rosetta.utility.vector1_double) -> NoneType
 
Sets the location of this node in k-space.
parent(...) from builtins.PyCapsule
parent(*args, **kwargs)
Overloaded function.
 
1. parent(rosetta.numeric.kdtree.KDNode) -> rosetta.numeric.kdtree.KDNode
 
Returns the parent of this KDNode in the tree,
 or NULL if there is no parent.
 
2. parent(self : rosetta.numeric.kdtree.KDNode, new_parent : rosetta.numeric.kdtree.KDNode) -> NoneType
 
Sets the parent for this node.
point(...) from builtins.PyCapsule
point(*args, **kwargs)
Overloaded function.
 
1. point(rosetta.numeric.kdtree.KDNode) -> rosetta.numeric.kdtree.KDPoint
 
2. point(self : rosetta.numeric.kdtree.KDNode, new_point : rosetta.numeric.kdtree.KDPoint) -> NoneType
right_child(...) from builtins.PyCapsule
right_child(*args, **kwargs)
Overloaded function.
 
1. right_child(rosetta.numeric.kdtree.KDNode) -> rosetta.numeric.kdtree.KDNode
 
Returns the right child of this KDNode in the tree,
 or NULL if there is no right child.
 
2. right_child(self : rosetta.numeric.kdtree.KDNode, new_right_child : rosetta.numeric.kdtree.KDNode) -> NoneType
 
Sets the right child for this node.
split_axis(...) from builtins.PyCapsule
split_axis(*args, **kwargs)
Overloaded function.
 
1. split_axis(rosetta.numeric.kdtree.KDNode) -> int
 
Returns the dimension along which this node splits points.
 
2. split_axis(self : rosetta.numeric.kdtree.KDNode, axis : int) -> NoneType
 
Sets the dimension along which this node splits points.
tree(...) from builtins.PyCapsule
tree(rosetta.numeric.kdtree.KDNode) -> rosetta.numeric.kdtree.KDTree
 
Returns a const reference to the Tree that contains
 this KDNode.

 
class KDPoint(builtins.object)
     Methods defined here:
__eq__(...) from builtins.PyCapsule
__eq__(self : rosetta.numeric.kdtree.KDPoint, other : rosetta.numeric.kdtree.KDPoint) -> bool
 
Equality operator. Compares location() and distance(),
 ignores data().
__init__(...) from builtins.PyCapsule
__init__(*args, **kwargs)
Overloaded function.
 
1. __init__(rosetta.numeric.kdtree.KDPoint) -> NoneType
 
2. __init__(self : rosetta.numeric.kdtree.KDPoint, location : rosetta.utility.vector1_double) -> NoneType
 
3. __init__(self : rosetta.numeric.kdtree.KDPoint, location : rosetta.utility.vector1_double, data : utility::pointer::ReferenceCount) -> NoneType
 
4. __init__(self : rosetta.numeric.kdtree.KDPoint, location : rosetta.utility.vector1_double, distance : float) -> NoneType
 
5. __init__(self : rosetta.numeric.kdtree.KDPoint, location : rosetta.utility.vector1_double, data : utility::pointer::ReferenceCount, distance : float) -> NoneType
 
6. __init__(self : rosetta.numeric.kdtree.KDPoint, src : rosetta.numeric.kdtree.KDPoint) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.
assign(...) from builtins.PyCapsule
assign(self : rosetta.numeric.kdtree.KDPoint, src : rosetta.numeric.kdtree.KDPoint) -> rosetta.numeric.kdtree.KDPoint
 
Assignment operator for KDPoint class.
const_location(...) from builtins.PyCapsule
const_location(rosetta.numeric.kdtree.KDPoint) -> rosetta.utility.vector1_double
 
Returns a const reference to the location of this point in
 k-space.
distance(...) from builtins.PyCapsule
distance(*args, **kwargs)
Overloaded function.
 
1. distance(rosetta.numeric.kdtree.KDPoint) -> float
 
getter for distance() from this point to an arbitrary point
 in kd-space.
 
2. distance(self : rosetta.numeric.kdtree.KDPoint, dist : float) -> NoneType
 
Sets the distance to an arbitrary point.
location(...) from builtins.PyCapsule
location(*args, **kwargs)
Overloaded function.
 
1. location(rosetta.numeric.kdtree.KDPoint) -> rosetta.utility.vector1_double
 
Returns to the location of this point in k-space.
 
2. location(self : rosetta.numeric.kdtree.KDPoint, dat : rosetta.utility.vector1_double) -> NoneType
 
sets the location of this point in k-space.
size(...) from builtins.PyCapsule
size(rosetta.numeric.kdtree.KDPoint) -> int
 
Returns the number of dimensions for the space in which this point
 lives.
to_string(...) from builtins.PyCapsule
to_string(rosetta.numeric.kdtree.KDPoint) -> str
 
Returns a stringified version of this object.

 
class KDPointList(builtins.object)
    Class for keeping track of the closest N KDPoint
objects by distance.
 
  Methods defined here:
__getitem__(...) from builtins.PyCapsule
__getitem__(self : rosetta.numeric.kdtree.KDPointList, pos : int) -> rosetta.numeric.kdtree.KDPoint
__init__(...) from builtins.PyCapsule
__init__(self : rosetta.numeric.kdtree.KDPointList, n_to_keep : int) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.
assign(...) from builtins.PyCapsule
assign(self : rosetta.numeric.kdtree.KDPointList,  : rosetta.numeric.kdtree.KDPointList) -> rosetta.numeric.kdtree.KDPointList
begin(...) from builtins.PyCapsule
begin(*args, **kwargs)
Overloaded function.
 
1. begin(rosetta.numeric.kdtree.KDPointList) -> __gnu_cxx::__normal_iterator<std::shared_ptr<numeric::kdtree::KDPoint> const*, std::vector<std::shared_ptr<numeric::kdtree::KDPoint>, std::allocator<std::shared_ptr<numeric::kdtree::KDPoint> > > >
 
2. begin(rosetta.numeric.kdtree.KDPointList) -> __gnu_cxx::__normal_iterator<std::shared_ptr<numeric::kdtree::KDPoint>*, std::vector<std::shared_ptr<numeric::kdtree::KDPoint>, std::allocator<std::shared_ptr<numeric::kdtree::KDPoint> > > >
distance_cutoff(...) from builtins.PyCapsule
distance_cutoff(*args, **kwargs)
Overloaded function.
 
1. distance_cutoff(rosetta.numeric.kdtree.KDPointList) -> float
 
2. distance_cutoff(self : rosetta.numeric.kdtree.KDPointList, cutoff : float) -> NoneType
end(...) from builtins.PyCapsule
end(*args, **kwargs)
Overloaded function.
 
1. end(rosetta.numeric.kdtree.KDPointList) -> __gnu_cxx::__normal_iterator<std::shared_ptr<numeric::kdtree::KDPoint> const*, std::vector<std::shared_ptr<numeric::kdtree::KDPoint>, std::allocator<std::shared_ptr<numeric::kdtree::KDPoint> > > >
 
2. end(rosetta.numeric.kdtree.KDPointList) -> __gnu_cxx::__normal_iterator<std::shared_ptr<numeric::kdtree::KDPoint>*, std::vector<std::shared_ptr<numeric::kdtree::KDPoint>, std::allocator<std::shared_ptr<numeric::kdtree::KDPoint> > > >
insert(...) from builtins.PyCapsule
insert(self : rosetta.numeric.kdtree.KDPointList, pt : rosetta.numeric.kdtree.KDPoint) -> NoneType
max_values(...) from builtins.PyCapsule
max_values(rosetta.numeric.kdtree.KDPointList) -> int
merge(...) from builtins.PyCapsule
merge(self : rosetta.numeric.kdtree.KDPointList, other : rosetta.numeric.kdtree.KDPointList) -> NoneType
 
merge another KDPointList with this KDPointList.
 This calls insert which is a little slow, and is a candidate for
 optimization if the insert() method shows up in profiling.
size(...) from builtins.PyCapsule
size(rosetta.numeric.kdtree.KDPointList) -> int
sorted_values(...) from builtins.PyCapsule
sorted_values(rosetta.numeric.kdtree.KDPointList) -> rosetta.utility.vector1_std_shared_ptr_numeric_kdtree_KDPoint_t
worst_distance(...) from builtins.PyCapsule
worst_distance(rosetta.numeric.kdtree.KDPointList) -> float

 
class KDPoint_MinDist(builtins.object)
     Methods defined here:
__call__(...) from builtins.PyCapsule
__call__(self : rosetta.numeric.kdtree.KDPoint_MinDist, a : rosetta.numeric.kdtree.KDPoint, b : rosetta.numeric.kdtree.KDPoint) -> bool
__init__(...) from builtins.PyCapsule
__init__(rosetta.numeric.kdtree.KDPoint_MinDist) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.

 
class KDTree(builtins.object)
     Methods defined here:
__init__(...) from builtins.PyCapsule
__init__(*args, **kwargs)
Overloaded function.
 
1. __init__(rosetta.numeric.kdtree.KDTree) -> NoneType
 
2. __init__(self : rosetta.numeric.kdtree.KDTree, pts : rosetta.utility.vector1_utility_vector1_double_std_allocator_double_t) -> NoneType
__new__(*args, **kwargs) from builtins.type
Create and return a new object.  See help(type) for accurate signature.
assign(...) from builtins.PyCapsule
assign(self : rosetta.numeric.kdtree.KDTree,  : rosetta.numeric.kdtree.KDTree) -> rosetta.numeric.kdtree.KDTree
bounds(...) from builtins.PyCapsule
bounds(rosetta.numeric.kdtree.KDTree) -> rosetta.numeric.kdtree.HyperRectangle
 
Returns the HyperRectangle that bounds all of the points in the
 kd-tree.
 
 
 A HyperRectangle is defined as two vectors upper and lower, with
 each dimension of lower having the minimum value seen in each dimension,
 and each dimension of higher having the maximum value seen in each
 dimension.
extend_bounds(...) from builtins.PyCapsule
extend_bounds(self : rosetta.numeric.kdtree.KDTree, pt : rosetta.utility.vector1_double) -> NoneType
 
Pushes out the bounds of the HyperRectangle bounding this kd-tree
 if necessary.
ndim(...) from builtins.PyCapsule
ndim(rosetta.numeric.kdtree.KDTree) -> int
 
Number of dimensions in the kd-tree. This is the "k" in kd.
root(...) from builtins.PyCapsule
root(*args, **kwargs)
Overloaded function.
 
1. root(rosetta.numeric.kdtree.KDTree) -> numeric::kdtree::KDNode
 
Returns the KDNodeOP that is the root of the balanced kd-tree.
 
2. root(self : rosetta.numeric.kdtree.KDTree, new_root : numeric::kdtree::KDNode) -> NoneType
 
Sets the root of the kd-tree.
size(...) from builtins.PyCapsule
size(*args, **kwargs)
Overloaded function.
 
1. size(rosetta.numeric.kdtree.KDTree) -> int
 
Number of points in the kd-tree.
 
2. size(self : rosetta.numeric.kdtree.KDTree, new_size : int) -> NoneType
 
Sets the number of points in this kd-tree.

 
Functions
       
construct_kd_tree(...) method of builtins.PyCapsule instance
construct_kd_tree(points : rosetta.utility.vector1_std_shared_ptr_numeric_kdtree_KDPoint_t, depth : int, tree : rosetta.numeric.kdtree.KDTree) -> rosetta.numeric.kdtree.KDNode
 
Function for constructing a KDTree. Returns a KDNodeOP that
 represents the root of the tree. Points need to be sorted as the
 tree is being constructed, so the reference to the points is non-const.
get_percentile_bounds(...) method of builtins.PyCapsule instance
get_percentile_bounds(points : rosetta.utility.vector1_utility_vector1_double_std_allocator_double_t) -> rosetta.numeric.kdtree.HyperRectangle
hr_intersects_hs(...) method of builtins.PyCapsule instance
hr_intersects_hs(hr : rosetta.numeric.kdtree.HyperRectangle, pt : rosetta.utility.vector1_double, r : float) -> bool
 
returns true if the given hyper-rectangle intersects with the given
 hypersphere.
is_legal_greater_than(...) method of builtins.PyCapsule instance
is_legal_greater_than(current : rosetta.numeric.kdtree.KDNode, split_axis : int, split_value : float) -> bool
is_legal_kdtree_below_node(...) method of builtins.PyCapsule instance
is_legal_kdtree_below_node(current : rosetta.numeric.kdtree.KDNode) -> bool
is_legal_less_than(...) method of builtins.PyCapsule instance
is_legal_less_than(current : rosetta.numeric.kdtree.KDNode, split_axis : int, split_value : float) -> bool
make_points(...) method of builtins.PyCapsule instance
make_points(points : rosetta.utility.vector1_utility_vector1_double_std_allocator_double_t) -> rosetta.utility.vector1_std_shared_ptr_numeric_kdtree_KDPoint_t
 
Makes a vector of KDPoints.
nearest_neighbor(...) method of builtins.PyCapsule instance
nearest_neighbor(*args, **kwargs)
Overloaded function.
 
1. nearest_neighbor(tree : rosetta.numeric.kdtree.KDTree, pt : rosetta.utility.vector1_double, nearest : rosetta.numeric.kdtree.KDNode, dist_sq : float) -> NoneType
 
Searches the KDtree for the nearest neigbor to a given input point,
 returns nearest neighbor and distance-squared to nearest neigbor by
 reference.
 
2. nearest_neighbor(current : rosetta.numeric.kdtree.KDNode, pt : rosetta.utility.vector1_double, bounds : rosetta.numeric.kdtree.HyperRectangle, max_dist_sq : float, nearest : rosetta.numeric.kdtree.KDNode, dist_sq : float) -> NoneType
 
returns the nearest neighbor to the given point.
 
 
 Parameters are (in order):
 - current: the base of the tree
 - pt: the point that is being searched against the tree
 - bounds: hyper-rectangle in k-space that bounds all points in the tree
 - max_dist_sq: maximum squared distance that we care about.
 
 - nearest neighbor (returned by reference)
 - squared distance to the nearest neighbor
nearest_neighbors(...) method of builtins.PyCapsule instance
nearest_neighbors(*args, **kwargs)
Overloaded function.
 
1. nearest_neighbors(tree : rosetta.numeric.kdtree.KDTree, pt : rosetta.utility.vector1_double, wanted : int) -> rosetta.numeric.kdtree.KDPointList
 
Returns a KDPointList of the N nearest neighbors from the KDTree to
 the given input point.
 
2. nearest_neighbors(tree : rosetta.numeric.kdtree.KDTree, pt : rosetta.utility.vector1_double, wanted : int, max_dist_allowed : float) -> rosetta.numeric.kdtree.KDPointList
 
3. nearest_neighbors(current : rosetta.numeric.kdtree.KDNode, pt : rosetta.utility.vector1_double, bounds : rosetta.numeric.kdtree.HyperRectangle, max_dist_sq : float, neighbors : rosetta.numeric.kdtree.KDPointList) -> NoneType
 
Recursive function definition for search for a list of the N nearest
 neighbors, where N is defined as a member variable of the KDPointList
 object.
sq_vec_distance(...) method of builtins.PyCapsule instance
sq_vec_distance(vec1 : rosetta.utility.vector1_double, vec2 : rosetta.utility.vector1_double) -> float
 
Returns the square of the Euclidean distance between the two points
 vec1 and vec2.
transform_percentile(...) method of builtins.PyCapsule instance
transform_percentile(*args, **kwargs)
Overloaded function.
 
1. transform_percentile(points : rosetta.utility.vector1_utility_vector1_double_std_allocator_double_t) -> NoneType
 
Transforms the list of points given into percentiles using
 a linear mapping from the input space to percentile-space for each
 variable.
 
 
 For each variable X in row R, replaces X with the quantity
 ( X - min(R) ) / ( max(R) - min(R) ). Runs in O(N) time.
 
2. transform_percentile(points : rosetta.utility.vector1_utility_vector1_double_std_allocator_double_t, bounds : rosetta.numeric.kdtree.HyperRectangle) -> NoneType
transform_percentile_single_pt(...) method of builtins.PyCapsule instance
transform_percentile_single_pt(point : rosetta.utility.vector1_double, bounds : rosetta.numeric.kdtree.HyperRectangle) -> NoneType
vec_distance(...) method of builtins.PyCapsule instance
vec_distance(vec1 : rosetta.utility.vector1_double, vec2 : rosetta.utility.vector1_double) -> float
 
Returns the Euclidean distance between the two points vec1 and vec2.