Github user sethah commented on a diff in the pull request:
https://github.com/apache/spark/pull/12374#discussion_r59646555
--- Diff:
mllib/src/main/scala/org/apache/spark/ml/tree/impl/RandomForest.scala ---
@@ -966,9 +972,9 @@ private[spark] object RandomForest extends Logging {
val valueCounts = valueCountMap.toSeq.sortBy(_._1).toArray
// if possible splits is not enough or just enough, just return all
possible splits
- val possibleSplits = valueCounts.length
+ val possibleSplits = valueCounts.length - 1
--- End diff --
The number of possible _bins_ should be `valueCounts.length`, and the
number of possible _splits_ should therefore be `valueCounts.length - 1`.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]