mirror of
https://github.com/Doctorado-ML/Odte.git
synced 2025-07-11 08:12:06 +00:00
Fix nodes_leaves for base_estimator
This commit is contained in:
parent
3558c946a8
commit
74343a15e1
@ -88,8 +88,9 @@ class Odte(BaseEnsemble, ClassifierMixin):
|
||||
return self
|
||||
|
||||
def _compute_metrics(self) -> None:
|
||||
tdepth = tnodes = tleaves = 0
|
||||
tdepth = tnodes = tleaves = 0.0
|
||||
for estimator in self.estimators_:
|
||||
if hasattr(estimator, "nodes_leaves"):
|
||||
nodes, leaves = estimator.nodes_leaves()
|
||||
depth = estimator.depth_
|
||||
tdepth += depth
|
||||
|
Loading…
x
Reference in New Issue
Block a user