NOPT(1SP)

NAME
nopt - Conjugate-gradient Neural-Net training program

SYNOPSIS
nopt [-i interval] [-t] [-c iter] [-v] [-h target_hi] [-l target_low] configfile vectorfile weightbase

DESCRIPTION
nopt is a neural net training program based on Conjugate-Gradient Descent optimization. It trains N layer feed-forward networks, where N is at least 3 (i.e. there is at least one hidden layer). Each layer is totally connected to the next. In addition to the input provided in the vector file, nopt appends an additional input with a constant value of 1.0. This replaces the use of a "bias" input.

configfile
    Network description for nopt.

vectorfile
    File containing the training vectors.

weightbase
    The base name of the file to which the weights will be written to.

OPTIONS

-i interval
    Sets the interval at which nopt writes weight files. Defaults to 100. The weight files names are of the form weightbase.inter, where inter is the current iteration count.

-c  iter
    nopt continues from the iter previous training session. This cause nopt to read in weightbase.iter before starting to train.

-v  Run in verbose mode.

-t  Causes nopt to report CPU usage on stderr.

-h target_hi
    Sets the hi target to target_hi (default 0.7).

-l target_low
    Sets the low target to target_low. (default 0.3).

CONFIGURATION FILE FORMAT

The configfile contains the discription of the neural net. This is a free-format text file containing the following information:

layers
    This is the number of layers in the neural net. The input and output layers are included in the count of layers, and it is assumed that layers is not less than 3; that is, the net has at least one hidden layer. This is an integer value.

max_iter
    The maximum number of iterations of the conjugate-gradient procedure that should be performed. This is an integer value.

stop_criterion
    If the norm of the gradient becomes less than stop_criterion training is terminated; otherwise, it continues until max_iter iterations have been completed. This is a real number.

seed
    A number with which the random weights are initialized. This is an integer number.

size1 size2 size3 ... sizeN
    List of the sizes of each of the layers size. size1 should equal the number of input features, and sizeN should be equal to the number of classes into which the samples are to be classified. These are integer numbers.

VECTOR FILE FORMAT

The vector file contains the training data for the neural net. This is a free-format file containing the following information:

samples
    The number of training samples in the file. This is an integer value.

Next comes the training samples. A training sample consist of:

class
    The class to which this sample belongs. This is an integer value numbered from 1 to the size of the output layer.

s1 s2 s3 .. sN
    These are the feature values for this sample. N should be the same as size1 from the configfile. To minimize local-minima problems, these features should be scaled so that all or almost all values are between -1.0 and 1.0. These values are real numbers.

EXAMPLES

Example configuration file named xor.conf

    3 130 0.0000001 1989
    2 3 2

Example vector file named xor.train

    4
    1 0.0 0.0
    2 0.0 1.0
    2 1.0 0.0
    1 1.0 1.0

Example run:

    % nopt -i 5 xor.conf xor.train xor

produces trained weight files xor.5 xor.10 etc.

SEE ALSO
noptest(1SP) noptreport(1SP) noptread(1SP)

BUGS
There must be at least one hidden layer.

AUTHORS
Etienne Barnard, Carnegie Mellon University