Fix SIGFPE in slow_conv3d_forward_out_cpu (#94325)
Set number of groups to 0 if weights second dimension is zero.
`slow_conv_shape_check` will raise an exception if groups are zero anyway.
Fixes SIGFPE reported in https://github.com/pytorch/pytorch/issues/94125
Pull Request resolved: https://github.com/pytorch/pytorch/pull/94325
Approved by: https://github.com/albanD