How a neural net makes cookies