neural_trees.Distilled#

class neural_trees.Distilled(student: Any, fidelity: float, fidelity_rules: float, tv_distance: float, n_splits: int, features_per_split: float, evaluated_on: str)[source]#

Bases: object

The student and how closely it follows the teacher.

Attributes:
studentSoftDecisionTree

The fitted soft tree.

fidelityfloat

Share of evaluated_on rows where the student predicts the teacher’s class.

fidelity_rulesfloat

The same for the student read as hard rules (to_hard_tree()), which is the model a person reads.

tv_distancefloat

Mean total-variation distance between the two probability vectors, 0 for identical, 1 for disjoint.

n_splitsint

Splits in the student.

features_per_splitfloat

Mean number of features carrying 90 % of a split’s absolute weight.

evaluated_onstr

"held-out" when X_eval was given, "training rows" otherwise.