Help Topics     Concepts     Package     Class


Neural Prediction Agent Properties and Use

Properties

The Neural Prediction Agent panel provides these options:

Training File Name
Enter the name of a definition file. Use the Browse button to select a definition file. This file will be used to specify the network architecture's input value since it defines the number of fields and their data type. One of the fields must have a field name of predicted to support supervised learning. The data itself must be a file by the same name with a .dat extension. This will be used when the mode is Train and also to Generate Beans.
Testing File Name
Enter the name of a definition file with the same layout as the training definition file. Use the Browse button to select a definition file. This will be used when you set the mode to Test and also when the training process uses Test mode to conditionally end training.
Agent Mode
Select one of the following agent modes:
Train implies that the network bean's weights are unlocked, and the import bean referencing the Training File provides the active data buffer connection.
Test implies that the network bean's weights are locked, and the percent correct is calculated; the import bean referencing the Testing File provides the active data buffer connection.
Run implies that the network bean's weights are locked and the percent correct is not calculated.
Test/Train Ratio
Once the desired accuracy specified by Maximum RMS Error is attained from training, this value controls additional training required to improve the network accuracy calculated from the test data. A ratio of 10 means that the network trains with the training data for 10 passes before switching to the test data to calculate the error from the records in the test data.
Architecture
The network architecture consists of five parameters:
  1. Inputs, which is calculated when beans are generated from the Training File.
  2. Hidden1, which is the number of hidden units in the first layer.
  3. Hidden2, which is the number of hidden units in the second layer.
  4. Hidden3, which is the number of hidden units in the third layer.
  5. Outputs, which is calculated when beans are generated from the Training File.
  6. Feedback, which adds value to time series forecasting. Select one of the following choices:
    None
    No feedback.
    Hidden layer
    Map the first hidden layer units back to the input layer, acting as an internal state or memory.
    Output layer
    Map the output layer units back to the input layer, using the previous network output as prior state information.
Window Size
Each input to the network represents data from one point in time. If multiple periods are needed for forecasting, specify the number of periods needed as the Window Size. If this value is greater than one, a time series filter is generated by the agent.
Horizon
Each input to the network represents data from one point in time. If the value to predict is several periods in the future, specify the number of periods as the Horizon. If this value is greater than zero, a time series filter is generated by the agent.
Tolerance
In Test mode the error is calculated for each record and compared to the Tolerance value. Errors greater than the tolerance value indicate a bad calculation. If the error is within the tolerance, it is treated as 0. Tolerance must be a real value between 0.0 and 1.0. In Training mode, Tolerance is set at the network bean level.
Maximum AveRMSError
Enter the threshold value for the maximum average root mean-squared error between the actual value and the value calculated by the network. Training the network will stop if and when the aveRMSError calculated by the contained neural network bean falls below this threshold for the test data.
Explicit error mode
Select explicit error mode if the input buffer during training contains the actual error value. Otherwise it is assumed to be the desired or target value. This is used in back propagating error for control applications.
Maximum Number of Passes
The threshold value for the maximum number of passes. Training the network will stop if this threshold is attained.

Use

The Neural Prediction Agent panel is used to generate an agent containing import beans for training and testing, a BackPropagation bean, filter beans to translate network inputs and outputs, a time series filter bean depending on the window size and horizon settings, and data connections between the beans as needed. The Agent Mode is set so that the network bean can be trained or used to provide an independant data source to test that training is sufficient.

Steps in using the panel for training include:

  1. Enter the name of the training file that defines the record layout and name of the training data source. If the file is read successfully, the Generate Beans button should be enabled.
  2. Select Train for the Agent Mode.
  3. Set the values for hidden unit layers, window size, and horizon.
  4. Press the Generate Beans button. The Start Training button should now be enabled.
  5. Set the Maximum RMS Error to control when training will stop, and the Tolerance as desired.
  6. Press the Start Training button to begin processing records through the data buffer connections. Once training has begun, this button's label will toggle to Stop Training. Training will continue until the toggled button is pressed, the accuracy threshold is met, or the Maximum Passes value is attained.
  7. You may wish to press the Stop Training button, change the Maximum RMS Error or Tolerance, and start again. If you change the network architecture, press Generate Beans for the changes to take effect. Press the Reset Beans button to re-initialize the network weights before starting training again if you wish.
  8. To use the test capability, enter a file in the Testing File Name field that uses same layout as the Training File definition. Once provided with the test data and after the network bean has trained to the specified accuracy with the training data, the training process internally switches to Test mode. It will enable the data buffer from the test import bean to calculate the RMS error from the test data with the network weights locked. If the required error calculated in the test data set is less than the maximum specified, training stops. Otherwise training continues for the number of passes specified by Train/Test Ratio before the accuracy is again calculated from the test data.