mirror of
https://github.com/Doctorado-ML/bayesclass.git
synced 2025-08-17 16:45:54 +00:00
fix AODE state_names mistake
This commit is contained in:
@@ -348,6 +348,7 @@ class AODE(BayesBase, BaseEnsemble):
|
|||||||
"""Build SPODE estimators (Super Parent One Dependent Estimator)"""
|
"""Build SPODE estimators (Super Parent One Dependent Estimator)"""
|
||||||
self.models_ = []
|
self.models_ = []
|
||||||
class_edges = [(self.class_name_, f) for f in self.features_]
|
class_edges = [(self.class_name_, f) for f in self.features_]
|
||||||
|
states = dict(state_names=kwargs.pop("state_names", []))
|
||||||
for idx in range(len(self.features_)):
|
for idx in range(len(self.features_)):
|
||||||
feature_edges = [
|
feature_edges = [
|
||||||
(self.features_[idx], f)
|
(self.features_[idx], f)
|
||||||
@@ -358,7 +359,6 @@ class AODE(BayesBase, BaseEnsemble):
|
|||||||
model = BayesianNetwork(
|
model = BayesianNetwork(
|
||||||
feature_edges, show_progress=self.show_progress
|
feature_edges, show_progress=self.show_progress
|
||||||
)
|
)
|
||||||
states = dict(state_names=kwargs.pop("state_names", []))
|
|
||||||
model.fit(
|
model.fit(
|
||||||
self.dataset_,
|
self.dataset_,
|
||||||
estimator=BayesianEstimator,
|
estimator=BayesianEstimator,
|
||||||
|
Reference in New Issue
Block a user