Fix classifier build in proposal

This commit is contained in:
2025-07-07 02:10:08 +02:00
parent 0ce7f664b4
commit 2c7352ac38
7 changed files with 29 additions and 16 deletions

View File

@@ -5,6 +5,7 @@
// ***************************************************************
#include "TANLd.h"
#include <memory>
namespace bayesnet {
TANLd::TANLd() : TAN(), Proposal(dataset, features, className) {}
@@ -17,7 +18,7 @@ namespace bayesnet {
y = y_;
// Use iterative local discretization instead of the two-phase approach
states = iterativeLocalDiscretization(y, this, dataset, features, className, states_, smoothing);
states = iterativeLocalDiscretization(y, static_cast<TAN*>(this), dataset, features, className, states_, smoothing);
// Final fit with converged discretization
TAN::fit(dataset, features, className, states, smoothing);
@@ -38,4 +39,4 @@ namespace bayesnet {
{
return TAN::graph(name);
}
}
}