23 std::vector<MVAUtils::index_t> right;
26 std::stack<const TMVA::DecisionTreeNode *>
parent;
27 std::stack<MVAUtils::index_t> parentIndex;
35 if (!currNode->GetLeft()) {
37 auto currParent =
parent.top();
38 auto currParentIndex = parentIndex.top();
40 if (currParentIndex >= 0) {
41 right[currParentIndex] =
i + 1 - currParentIndex;
42 currNode = currParent->GetCutType() ? currParent->GetLeft() : currParent->GetRight();
52 currNode = currNode->GetCutType() ? currNode->GetRight() : currNode->GetLeft();
58 std::stack<const TMVA::DecisionTreeNode *>
parent;
64 std::vector<MVAUtils::NodeTMVA> nodes;
67 if (!currNode->GetLeft()){
69 nodes.emplace_back(-1,
71 currNode->GetResponse() : useYesNoLeaf ? currNode->GetNodeType() : currNode->GetPurity(),
73 auto currParent =
parent.top();
76 currNode = currParent->GetCutType() ? currParent->GetLeft() : currParent->GetRight();
85 if (currNode->GetSelector() >max_var) { max_var = currNode->GetSelector(); }
87 nodes.emplace_back(currNode->GetSelector(), currNode->GetCutValue(), right[
i]);
89 currNode = currNode->GetCutType() ? currNode->GetRight() : currNode->GetLeft();