Error message for grouped convolution backprop on CPU is uninformative

Hello, I recently learned that gradients and backprop for grouped convolution is not supported on CPU, as discussed in the following github threads:

Nothing on the documentation for convolution with grouping indicated I would run into this issue, and the error message that came up when I attempted to run the optimizer (copied below) was very unhelpful for diagnosing the source of the issue.

InvalidArgumentError: Computed input depth 32 doesn't match filter input depth 4 [Op:Conv2DBackpropInput]

I did not expect to see a backprop operation for Conv2D when my model was only using Conv1D layers, and I only figured out the issue was related to grouping because I was very familiar with the parameters of the model I was running.

I believe adding the following features would make it much easier for future developers to diagnose the issue:

  • A more informative error message when you attempt to run backprop on a grouped convolution layer on CPU
  • Possibly a warning when you load a grouped convolution layer on CPU at all
  • A note in the documentation for convolution layers that gradients for grouped convolution is only supported on GPU

Thank you.

1 Like