DSP Utils (libnmfd.utils.dsp_utils)¶
- libnmfd.utils.dsp_utils.conv2(x: numpy.ndarray, y: numpy.ndarray, mode: str = 'same') → numpy.ndarray[source]¶
Emulate the function conv2 from Mathworks. Usage: z = conv2(x,y,mode=’same’)
- Parameters
x (np.ndarray) – The sequence / matrix to be convolved with the kernel y
y (np.ndarray) – The convolution kernel
mode (str) – The mode of convolution, only ‘same’ is supported
- Returns
z (np.ndarray) – The result of the conv2 operation