Github user jkbradley commented on a diff in the pull request:
https://github.com/apache/spark/pull/20786#discussion_r175959372
--- Diff: mllib/src/main/scala/org/apache/spark/ml/tree/treeModels.scala ---
@@ -306,17 +304,21 @@ private[ml] object DecisionTreeModelReadWrite {
* The nodes are returned in pre-order traversal (root first)
so that it is easy to
* get the ID of the subtree's root node.
*/
- def build(node: Node, id: Int): (Seq[NodeData], Int) = node match {
- case n: InternalNode =>
+ def build(node: Node, id: Int): (Seq[NodeData], Int) = {
--- End diff --
ditto: why change this?
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]