Function fann_sys::fann_create_standard[][src]

pub unsafe extern "C" fn fann_create_standard(
    num_layers: c_uint,
     ...
) -> *mut fann

Creates a standard fully connected backpropagation neural network.

There will be a bias neuron in each layer (except the output layer), and this bias neuron will be connected to all neurons in the next layer. When running the network, the bias nodes always emit 1.

To destroy a fann use the fann_destroy function.

Parameters

  • num_layers - The total number of layers including the input and the output layer.
  • ... - Integer values determining the number of neurons in each layer starting with the input layer and ending with the output layer.

Returns

A pointer to the newly created fann.

Example

// Creating an ANN with 2 input neurons, 1 output neuron,
// and two hidden layers with 8 and 9 neurons
unsafe {
    let ann = fann_sys::fann_create_standard(4, 2, 8, 9, 1);
}

This function appears in FANN >= 2.0.0.