F_VN_CreateStaModel
Create a Simplified TopoART neural network of the specified type. The initial reference count is set to one if a new model is created and kept, otherwise. Models of this type support on-line training (sample by sample), retraining, as well as scalar and vectorial predictions. It requires all input except class labels (i.e., samples and training outputs/predictions) to lie in the interval [0.0, 1.0]. The predictions of regressors need to be rescaled from the interval [0.0, 1.0] to their respective value range before usage. Depending on the parameter settings and the number of available training samples, repeated training with the same data may improve the results. Like other neural networks based on the Adaptive Resonance Theory (ART), Simplified TopoART neural networks are not prone to catastrophic inference and patricularly well-suited to incremental learning tasks.
Syntax
Definition:
FUNCTION F_VN_CreateStaModel : HRESULT
VAR_INPUT
ipMlModel : Reference To ITcVnMlModel;
eStaType : ETcVnSta;
fRho : LREAL;
hrPrev : HRESULT;
END_VAR
Inputs
Name |
Type |
Description |
---|---|---|
ipMlModel |
Reference To ITcVnMlModel |
Returns the created model (Non-zero interface pointers are reused.) |
eStaType |
Simpified TopoART model type | |
fRho |
LREAL |
Vigilance parameter (controls the number of neurons that are inserted and the maximum size of the formed categories; valid range: [0.0, 1.0]; suggested range: [0.8, 1.0)) |
hrPrev |
HRESULT indicating the result of previous operations (If SUCCEEDED(hrPrev) equals false, no operation is executed.) |
Further information
The function F_VN_CreateStaModel
creates a Simplified TopoART (STA) model.
Simplified TopoART models
The Simplified TopoART network learns sub-areas of the feature space. Depending on the application, these are grouped into clusters, assigned to classes or used for prediction. Due to the incremental architecture, post-training is possible, whereby the information already learned is retained in the best possible way. Only values in the interval of 0.0 and 1.0 are accepted as inputs (with the exception of class names). It is therefore advisable to use a feature normalization.
Model
The created model is returned in the interface pointer ipMlModel
.
Model type
eStaType
specifies whether the STA model is used for classification (TCVN_STA_CLASSIFIER
), regression (TCVN_STA_REGRESSOR
), clustering (TCVN_STA_CLUSTERER
) or anomaly detection (TCVN_STA_NOVELTY_DETECTOR
).
Vigilance parameters
This parameter is crucial for adapting the model to the respective task, as it controls the maximum size of the sub-areas to be learned.
Expert parameters
The expert variants F_VN_CreateStaModelExp and F_VN_CreateStaModelExp2 contain additional parameters.
Application
For example, an STA model for classification can be created like this:
hr := F_VN_CreateStaModel(
ipMlModel := ipMlModel,
eStaType := TCVN_STA_CLASSIFIER,
fRho := 0.9,
hrPrev := hr);
Required License
TC3 Vision Machine Learning
System Requirements
Development environment | Target platform | PLC libraries to include |
---|---|---|
TwinCAT V3.1.4024.54 or later | PC or CX (x64) with PL50, e.g. Intel 4-core Atom CPU | Tc3_Vision |