combining main and neuralnet