seldonian.parse_tree.parse_tree.make_parse_trees_from_constraints¶
- make_parse_trees_from_constraints(constraint_strs, deltas, regime='supervised_learning', sub_regime='regression', columns=[], delta_weight_method='equal')¶
Convenience function for creating parse trees given constraint strings and deltas
- Parameters:
constraint_strs – List of constraint strings
deltas – List of deltas corresponding to each constraint
regime (str, defaults to "supervised_learning") – The category of the machine learning algorithm, e.g., supervised_learning or reinforcement_learning
sub_regime (str, defults to "regression") – The sub-category of the machine learning algorithm, e.g., classifiction or regression
columns – list of columns in the dataset, needed if constraints condition on any of these columns
delta_weight_method (str, defults to "equal") – The method for weighting deltas across the base nodes.