/** * Constructor. The activation function of output layer will be chosen * by natural pairing based on the error function and the number of * classes. * * @param error the error function. * @param numUnits the number of units in each layer. */ public NeuralNetwork(ErrorFunction error, int... numUnits) { this(error, natural(error, numUnits[numUnits.length-1]), numUnits); }