Creating a neural network discriminator