Add maxpooling and maxpoolingundo functions.