neural network model in Python