code: def fir_zero_filter(coeff, timeseries):
      
      # apply the filter
      series = lfilter(coeff, timeseries.numpy())
  
      # reverse the time shift caused by the filter,
      # corruption regions contain zeros
      # If the number of filter coefficients is odd, the central point *should*
      # be included in the output so we only zero out a region of len(coeff) - 1
      data = numpy.zeros(len(timeseries))
      data[len(coeff)//2:len(data)-len(coeff)//2] = series[(len(coeff) // 2) * 2:]
      return data
docs: Filter the timeseries with a set of FIR coefficients
  
      Parameters
      ----------
      coeff: numpy.ndarray
          FIR coefficients. Should be and odd length and symmetric.
      timeseries: pycbc.types.TimeSeries
          Time series to be filtered.
  
      Returns
      -------
      filtered_series: pycbc.types.TimeSeries
          Return the filtered timeseries, which has been properly shifted to account
      for the FIR filter delay and the corrupted regions zeroed out.