Skip to content

Commit

Permalink
Update rank test and comments
Browse files Browse the repository at this point in the history
  • Loading branch information
reidjohnson committed Sep 4, 2024
1 parent 087d8e9 commit 7081e51
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions quantile_forest/_quantile_forest_fast.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -885,6 +885,7 @@ cdef class QuantileForest:
if train_indices[k].size() == 0:
continue

# Clear list of training target values.
leaf_samples.clear()

# Get training target values associated with indices.
Expand Down
1 change: 1 addition & 0 deletions quantile_forest/tests/test_quantile_forest.py
Original file line number Diff line number Diff line change
Expand Up @@ -680,6 +680,7 @@ def check_quantile_ranks(name):
assert y_ranks.shape == (X_test.shape[0], 2)
assert np.all(y_ranks >= 0)
assert np.all(y_ranks <= 1)
assert np.all(y_ranks[:, 0] < y_ranks[:, 1])


@pytest.mark.parametrize("name", FOREST_REGRESSORS)
Expand Down

0 comments on commit 7081e51

Please sign in to comment.