fann_sys::fann_cascadetrain_on_data [] [src]

pub unsafe extern fn fann_cascadetrain_on_data(ann: *mut fann, data: *const fann_train_data, max_neurons: c_uint, neurons_between_reports: c_uint, desired_error: c_float)

Trains on an entire dataset, for a period of time using the Cascade2 training algorithm. This algorithm adds neurons to the neural network while training, which means that it needs to start with an ANN without any hidden layers. The neural network should also use shortcut connections, so fann_create_shortcut should be used to create the ANN like this:

let ann = fann_create_shortcut(2,
                               fann_num_input_train_data(train_data),
                               fann_num_output_train_data(train_data));

This training uses the parameters set using fann_set_cascade_..., but it also uses another training algorithm as it's internal training algorithm. This algorithm can be set to either FANN_TRAIN_RPROP or FANN_TRAIN_QUICKPROP by fann_set_training_algorithm, and the parameters set for these training algorithms will also affect the cascade training.

Parameters

Instead of printing out reports every neurons_between_reports, a callback function can be called (see fann_set_callback).

See also

fann_train_on_data, fann_cascadetrain_on_file

This function appears in FANN >= 2.0.0.