code: def downsample_blocking(frames, hop_s, dtype="float32"):
      # downmixing to one channel
      if len(frames.shape) != 1:
          downsampled = frames.sum(axis=-1) / frames.shape[-1]
      else:
          downsampled = frames
      # zero padding to have a multiple of hop_s
      if downsampled.shape[0] % hop_s != 0:
          pad_length = (
              hop_s
              + downsampled.shape[0] / hop_s * hop_s
              - downsampled.shape[0]
          )
          downsampled = np.hstack(
              [downsampled, np.zeros(pad_length, dtype=dtype)]
          )
      # blocking
      return downsampled.reshape(downsampled.shape[0] / hop_s, hop_s)
  
imports: import numpy
label_desc: Use image node_id 1 for calling a global function with example usage: downsample_blocking(frames, hop_s, dtype) and returns: downsampled