Artificial neural network for speech recognition