Skip to content

Commit 62f0c60

Browse files
committed
Update docstring
Signed-off-by: Adam Li <adam2392@gmail.com>
1 parent 4627339 commit 62f0c60

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

sklearn/tree/_tree.pyx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -982,7 +982,7 @@ cdef class BestFirstTreeBuilder(TreeBuilder):
982982
cdef class BaseTree:
983983
"""Base class for Cython tree models.
984984
985-
Downstream classes must implement
985+
Downstream classes must implement methods to actually traverse the tree.
986986
"""
987987
cdef int _resize(
988988
self,
@@ -1712,6 +1712,10 @@ cdef class Tree(BaseTree):
17121712
weighted_n_node_samples : array of double, shape [node_count]
17131713
weighted_n_node_samples[i] holds the weighted number of training samples
17141714
reaching node i.
1715+
1716+
leaf_node_samples : dict of node id to numpy array of shapes (n_samples_node, n_features)
1717+
A dictionary mapping leaf nodes to the samples of data that are used
1718+
to fit the prediction at each leaf.
17151719
"""
17161720
# Wrap for outside world.
17171721
# WARNING: these reference the current `nodes` and `value` buffers, which

0 commit comments

Comments
 (0)