MeLOn
Loading...
Searching...
No Matches
melon::SvmParser Class Reference

This class implements a support vector machine file parser. More...

#include <svmParser.h>

Inheritance diagram for melon::SvmParser:
melon::ModelParser

Public Member Functions

std::shared_ptr< ModelDataparse_model (const std::string modelPath, const std::string modelName) override
 Function for parsing the support vector machine data from a file.
 
- Public Member Functions inherited from melon::ModelParser
virtual ~ModelParser ()=default
 Virtual desctructor to enable inheritance.
 

Static Public Member Functions

static KERNEL_FUNCTION string_to_kernel_function (const std::string &kernelName)
 Turns string with kernel name into enum representation.
 
static std::shared_ptr< ScalerDataparse_scaler (json scalerJson)
 Function for parsing scaler data from json object.
 

Additional Inherited Members

- Protected Member Functions inherited from melon::ModelParser
std::string _format_file_path (const std::string modelPath, const std::string modelName, const MODEL_FILE_TYPE fileType)
 Applies the correct format to the path given by the user.
 
std::string _format_folder_path (const std::string modelPath)
 Applies the correct format to the path given by the user.
 
- Static Protected Member Functions inherited from melon::ModelParser
static SCALER_TYPE _string_to_scaler_type (const std::string scalerTypeName)
 Turns a string containing the name of an scaler type in the correct enum representation.
 
static SCALER_PARAMETER _string_to_scaler_parameter (const std::string scalerParameterName)
 Turns a string containing the name of an scaler type in the correct enum representation.
 
- Protected Attributes inherited from melon::ModelParser
std::string _modelPath
 
std::string _modelName
 

Detailed Description

This class implements a support vector machine file parser.

Member Function Documentation

◆ parse_model()

std::shared_ptr< ModelData > SvmParser::parse_model ( const std::string modelPath,
const std::string modelName )
overridevirtual

Function for parsing the support vector machine data from a file.

Parameters
[in]modelPathPath to the location of the support vector machine file
[in]modelNamename of the model
Returns
returns modelData struct containing the information defining the support vector machine

Implements melon::ModelParser.

◆ parse_scaler()

std::shared_ptr< ScalerData > SvmParser::parse_scaler ( json scalerJson)
static

Function for parsing scaler data from json object.

Parameters
[in]scalerJsonjson object containing the scaler specifications
Returns
returns a scaler data object containing the data rewuired to create the specified scaler.

◆ string_to_kernel_function()

KERNEL_FUNCTION SvmParser::string_to_kernel_function ( const std::string & kernelName)
static

Turns string with kernel name into enum representation.

Parameters
[in]kernelNameis a std::string with the kernel name
Returns
returns the enum representation of file type

The documentation for this class was generated from the following files: