Add support for subsampling and gradient to GpuDnnConv

This adds a grad() method to GpuDnnConv and adds support for subsampling.  It also allows choosing between convolution and cross-correlation mode (however cross-correlation mode has not been tested).

I've also made a base class that create the cudnn handle to make other ops easier to write.
I admit that was ugly, I just didn't want to change the indentation of everything below. Instead of doing three yield statements below, I'd suggest `for subsx, subsy in (1,1), (1,2), (2,2):`