alessandrobenedetti commented on a change in pull request #242: URL: https://github.com/apache/solr/pull/242#discussion_r683276114
########## File path: solr/contrib/ltr/src/java/org/apache/solr/ltr/model/MultipleAdditiveTreesModel.java ########## @@ -292,10 +291,10 @@ private static float scoreNode(float[] featureVector, RegressionTreeNode regress return 0f; } - if (featureVector[regressionTreeNode.featureIndex] <= regressionTreeNode.threshold) { - regressionTreeNode = regressionTreeNode.left; - } else { + if (featureVector[regressionTreeNode.featureIndex] >= regressionTreeNode.threshold) { Review comment: I think we should keep it consistent, isn't <= in XGboost and similar? This is a pretty big change, and I think it shouldn't be necssary ########## File path: solr/contrib/ltr/src/test-files/modelExamples/multipleadditivetreesmodel_split_at_threshold.json ########## @@ -0,0 +1,23 @@ +{ + "class":"org.apache.solr.ltr.model.MultipleAdditiveTreesModel", + "name":"multipleadditivetreesmodel_split_at_threshold", + "features":[ + { "name": "constantScoreToForceMultipleAdditiveTreesScoreAllDocs"} + ], + "params":{ + "trees": [ + { + "weight" : "1f", + "root": { + "feature": "constantScoreToForceMultipleAdditiveTreesScoreAllDocs", + "threshold": "1.0f", Review comment: we should verify this, I think branching is generated on <=left and > right ########## File path: solr/contrib/ltr/src/test-files/modelExamples/multipleadditivetreesmodel_split_at_threshold.json ########## @@ -0,0 +1,23 @@ +{ + "class":"org.apache.solr.ltr.model.MultipleAdditiveTreesModel", + "name":"multipleadditivetreesmodel_split_at_threshold", + "features":[ + { "name": "constantScoreToForceMultipleAdditiveTreesScoreAllDocs"} + ], + "params":{ + "trees": [ + { + "weight" : "1f", + "root": { + "feature": "constantScoreToForceMultipleAdditiveTreesScoreAllDocs", + "threshold": "1.0f", Review comment: we should verify this, I think branching is generated on <=left and > right in the training algorithm -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org