Implement neural network functions to setup network weights, train a network, and use a network for prediction.