Skip to content
Snippets Groups Projects
Commit eef3cce4 authored by Ludovic Hussonnois's avatar Ludovic Hussonnois
Browse files

REFAC: Move function and remove comment.

parent 9cda28c8
No related branches found
No related tags found
No related merge requests found
......@@ -154,17 +154,10 @@ public:
/**
* Retrieve the classifier category (supervisde or unsupervised)
* based on the select algorithm from the classifier choice
* based on the select algorithm from the classifier choice.
* @return ClassifierCategory the classifier category
*/
inline ClassifierCategory GetClassifierCategory()
{
std::cout << GetParameterString("classifier") << std::endl;
bool foundUnsupervised =
std::find(m_UnsupervisedClassifier.begin(), m_UnsupervisedClassifier.end(),
GetParameterString("classifier")) != m_UnsupervisedClassifier.end();
return foundUnsupervised ? Unsupervised : Supervised;
}
ClassifierCategory GetClassifierCategory();
protected:
LearningApplicationBase();
......
......@@ -63,22 +63,22 @@ LearningApplicationBase<TInputValue,TOutputValue>
m_UnsupervisedClassifier.assign(allClassifier.begin() + m_SupervisedClassifier.size(), allClassifier.end());
}
template <class TInputValue, class TOutputValue>
typename LearningApplicationBase<TInputValue,TOutputValue>::ClassifierCategory
LearningApplicationBase<TInputValue,TOutputValue>
::GetClassifierCategory()
{
bool foundUnsupervised =
std::find(m_UnsupervisedClassifier.begin(), m_UnsupervisedClassifier.end(),
GetParameterString("classifier")) != m_UnsupervisedClassifier.end();
return foundUnsupervised ? Unsupervised : Supervised;
}
template <class TInputValue, class TOutputValue>
void
LearningApplicationBase<TInputValue,TOutputValue>
::DoUpdateParameters()
{
/*
// if the classifier category is changed, reload the corresponding classifier
if( HasValue( "category" ) )
{
//ClearChoices( "classifier" );
if( GetParameterString( "category" ) == "supervised" )
InitSupervisedClassifierParams();
else
InitUnsupervisedClassifierParams();
}
*/
};
template <class TInputValue, class TOutputValue>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment