You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
VisualisationNotYetSupportedError: get_node_criterion() is not implemented yet for LightGBM. Please create an issue on https://github.com/parrt/dtreeviz/issues if you need this. Thanks!
The text was updated successfully, but these errors were encountered:
VisualisationNotYetSupportedError Traceback (most recent call last)
/tmp/ipykernel_2428904/1600097902.py in ()
----> 1 viz_model.leaf_purity()
~/anaconda3/envs/myenv/lib/python3.8/site-packages/dtreeviz/trees.py in leaf_purity(self, display_type, colors, fontsize, fontname, grid, bins, figsize, ax)
755 :return:
756 """
--> 757 leaf_id, leaf_criteria = self.shadow_tree.get_leaf_criterion()
758
759 if display_type == "text":
~/anaconda3/envs/myenv/lib/python3.8/site-packages/dtreeviz/models/shadow_decision_tree.py in get_leaf_criterion(self)
369 For regression, supported criteria are “mse”, “friedman_mse”, “mae”.
370 """
--> 371 leaf_criterion = [(node.id, node.criterion()) for node in self.leaves]
372 x, y = zip(*leaf_criterion)
373 return np.array(x), np.array(y)
~/anaconda3/envs/myenv/lib/python3.8/site-packages/dtreeviz/models/shadow_decision_tree.py in (.0)
369 For regression, supported criteria are “mse”, “friedman_mse”, “mae”.
370 """
--> 371 leaf_criterion = [(node.id, node.criterion()) for node in self.leaves]
372 x, y = zip(*leaf_criterion)
373 return np.array(x), np.array(y)
~/anaconda3/envs/myenv/lib/python3.8/site-packages/dtreeviz/models/shadow_decision_tree.py in criterion(self)
531
532 def criterion(self):
--> 533 return self.shadow_tree.get_node_criterion(self.id)
534
535 def split_samples(self) -> Tuple[np.ndarray, np.ndarray]:
~/anaconda3/envs/myenv/lib/python3.8/site-packages/dtreeviz/models/lightgbm_decision_tree.py) in get_node_criterion(self, id)
203
204 def get_node_criterion(self, id):
--> 205 raise VisualisationNotYetSupportedError("get_node_criterion()", "LightGBM")
206
207 def get_feature_path_importance(self, node_list):
VisualisationNotYetSupportedError: get_node_criterion() is not implemented yet for LightGBM. Please create an issue on https://github.com/parrt/dtreeviz/issues if you need this. Thanks!
The text was updated successfully, but these errors were encountered: