title: 4D-convolution on Python
body: <p>I don't understand a few things in 4D-convolution. I have input tensor with dimension
  (5, 3, 17, 5), where:</p>
  <pre><code>batch_amount = 5
  tensor_Height = 3
  tensor_Weight = 17
  tensor_Cin = 5
  </code></pre>
  <p>Parameters of kernel (3, 3, 5, 2):</p>
  <pre><code>kernel_X = 3
  kernel_Y = 3
  kernel_depth = 5
  kernel_amount or C_out = 2
  </code></pre>
  <p>The bias is (2,):</p>
  <pre><code>b = [0.31862102 1.98459104]
  </code></pre>
  <p>How can I implement convolution and forward propagation with the current parameters using only numpy.</p>
  <p>I tried to follow the example of this:</p>
  <pre><code>def stride_conv(arr1,arr2,s,p):
      beg = 0
      end = arr2.shape[0]
      final = []
      for i in range(0,arr1.shape[0]-1,s):
          k = []
          for j in range(0,arr1.shape[0]-1,s):
              k.append(np.sum(arr1[beg+i : end+i, beg+j:end+j] * (arr2)))
          final.append(k)
  
      return np.array(final)
  </code></pre>