tf.keras.layers.AveragePooling3D crash
@cheyennee,

Looks like this is a duplicate of the issue [#56833](https://github.com/tensorflow/tensorflow/issues/56833). Could you please check and let us know if it is the same? Thank you!
 Hi, @tilakrayal,
I believe these issues involve distinct factors. Specifically, in this issues, the error arises due to setting the strides to 0 in tf.keras.layers.AveragePooling3D. It's my understanding that the strides parameter in this context must be greater than 0; a stride of 0 is not permitted. Conversely, in issue #56833, the parameters used in tf.keras.layers.MaxPooling3D are all valid.
### Issue type

Bug

### Have you reproduced the bug with TensorFlow Nightly?

No

### Source

source

### TensorFlow version

tf 2.14.0

### Custom code

Yes

### OS platform and distribution

windows colab

### Mobile device

_No response_

### Python version

3.10

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

_No response_

### Current behavior?

I run this code in colab, the colab crash and throw error message:
```
NotFoundError                             Traceback (most recent call last)
[<ipython-input-5-afbc98afe688>](https://localhost:8080/#) in <cell line: 15>()
     13 __input___0 = tf.identity(__input___0_tensor)
     14 AveragePooling3D_class = tf.keras.layers.AveragePooling3D(pool_size=pool_size, strides=strides, padding=padding, data_format=data_format,  dtype=tf.float64)
---> 15 print(AveragePooling3D_class(__input___0))
     16 # def wrap_func_exec():
     17 #   pool_size_0 = 3

1 frames
[/usr/local/lib/python3.10/dist-packages/tensorflow/python/eager/execute.py](https://localhost:8080/#) in quick_execute(op_name, num_outputs, inputs, attrs, ctx, name)
     58         for t in inputs
     59     ]
---> 60     tensors = pywrap_tfe.TFE_Py_Execute(ctx._handle, device_name, op_name,
     61                                         inputs, attrs, num_outputs)
     62   except core._NotOkStatusException as e:

NotFoundError: Exception encountered when calling layer 'average_pooling3d_6' (type AveragePooling3D).

Could not find device for node: {{node AvgPool3D}} = AvgPool3D[T=DT_DOUBLE, data_format="NDHWC", ksize=[1, 3, 3, 3, 1], padding="VALID", strides=[1, 0, 21, 1, 1]]
All kernels registered for op AvgPool3D:
  device='XLA_GPU_JIT'; T in [DT_FLOAT, DT_DOUBLE, DT_BFLOAT16, DT_HALF]
  device='XLA_CPU_JIT'; T in [DT_FLOAT, DT_DOUBLE, DT_BFLOAT16, DT_HALF]
  device='CPU'; T in [DT_BFLOAT16]
  device='CPU'; T in [DT_FLOAT]
  device='GPU'; T in [DT_BFLOAT16]
  device='GPU'; T in [DT_HALF]
  device='GPU'; T in [DT_FLOAT]
 [Op:AvgPool3D]

Call arguments received by layer 'average_pooling3d_6' (type AveragePooling3D):
  • inputs=tf.Tensor(shape=(1, 11, 1, 1, 1), dtype=float64)
```

I also run this code in pycharm, the pycharm exits directly and ```the pycharm process finished with exit code -1073741819 (0xC0000005)```

### Standalone code to reproduce the issue

```shell
import tensorflow as tf
pool_size_0 = 3
pool_size_1 = 3
pool_size_2 = 3
pool_size = [pool_size_0,pool_size_1,pool_size_2,]
strides_0 = 0
strides_1 = 21.0
strides_2 = 1
strides = [strides_0,strides_1,strides_2,]
padding = "valid"
data_format = "channels_last"
__input___0_tensor = tf.random.uniform([1, 11, 1, 1, 1], minval=-1.0, maxval=0.7764022115238914, dtype=tf.float32)
__input___0 = tf.identity(__input___0_tensor)
AveragePooling3D_class = tf.keras.layers.AveragePooling3D(pool_size=pool_size, strides=strides, padding=padding, data_format=data_format,  dtype=tf.float64)
print(AveragePooling3D_class(__input___0))
```


### Relevant log output

_No response_