26 #ifndef GRT_POST_PROCESSING_HEADER 27 #define GRT_POST_PROCESSING_HEADER 64 bool copyBaseVariables(
const PostProcessing *postProcessingModule);
77 UINT getPostProcessingInputMode()
const;
82 UINT getPostProcessingOutputMode()
const;
89 bool getInitialized()
const;
94 bool getIsPostProcessingInputModePredictedClassLabel()
const;
99 bool getIsPostProcessingInputModeClassLikelihoods()
const;
104 bool getIsPostProcessingOutputModePredictedClassLabel()
const;
109 bool getIsPostProcessingOutputModeClassLikelihoods()
const;
127 static PostProcessing* create(
const std::string &postProcessingType);
134 enum PostprocessingInputModes{INPUT_MODE_NOT_SET=0,INPUT_MODE_PREDICTED_CLASS_LABEL,INPUT_MODE_CLASS_LIKELIHOODS};
135 enum PostprocessingOutputModes{OUTPUT_MODE_NOT_SET=0,OUTPUT_MODE_PREDICTED_CLASS_LABEL,OUTPUT_MODE_CLASS_LIKELIHOODS};
138 GRT_DEPRECATED_MSG(
"createInstanceFromString is deprecated, use create instead.",
static PostProcessing* createInstanceFromString(
const std::string &
id ) );
139 GRT_DEPRECATED_MSG(
"getPostProcessingType is deprecated, use getId() instead", std::string getPostProcessingType()
const );
155 bool savePostProcessingSettingsToFile(std::fstream &file)
const;
162 bool loadPostProcessingSettingsFromFile(std::fstream &file);
164 std::string postProcessingType;
166 UINT postProcessingInputMode;
167 UINT postProcessingOutputMode;
170 static StringPostProcessingMap *getMap() {
171 if( !stringPostProcessingMap ){ stringPostProcessingMap =
new StringPostProcessingMap; }
172 return stringPostProcessingMap;
176 static StringPostProcessingMap *stringPostProcessingMap;
177 static UINT numPostProcessingInstances;
182 template<
typename T >
186 getMap()->insert( std::pair< std::string,
PostProcessing*(*)() >(newModuleId, &createNewPostProcessingModule< T > ) );
192 #endif //GRT_POST_PROCESSING_HEADER virtual bool deepCopyFrom(const PostProcessing *postProcessing)
virtual bool process(const VectorFloat &inputVector)
This is the main base class that all GRT PostProcessing algorithms should inherit from...
PostProcessing * createNewPostProcessingModule()
Returns a pointer to a new instance of the template class, the caller is responsible for deleting the...
GRT_DEPRECATED_MSG("saveModelToFile(std::string filename) is deprecated, use save(const std::string &filename) instead", virtual bool saveModelToFile(const std::string &filename) const )
This is the main base class that all GRT machine learning algorithms should inherit from...
std::map< std::string, PostProcessing *(*)() > StringPostProcessingMap