nvidia.dali.experimental.dynamic.preemphasis_filter#

nvidia.dali.experimental.dynamic.preemphasis_filter(input, /, *, batch_size=None, device=None, border=None, dtype=None, preemph_coeff=None)#

Applies preemphasis filter to the input data.

This filter, in simple form, can be expressed by the formula:

Y[t] = X[t] - coeff * X[t-1]    if t > 1
Y[t] = X[t] - coeff * X_border  if t == 0

with X and Y being the input and output signal, respectively.

The value of X_border depends on the border argument:

X_border = 0                    if border_type == 'zero'
X_border = X[0]                 if border_type == 'clamp'
X_border = X[1]                 if border_type == 'reflect'
Supported backends
  • ‘cpu’

  • ‘gpu’

Parameters:

input (Tensor/Batch) – Input to the operator.

Keyword Arguments:
  • border (str, optional, default = ‘clamp’) – Border value policy. Possible values are "zero", "clamp", "reflect".

  • dtype (nvidia.dali.types.DALIDataType, optional, default = DALIDataType.FLOAT) – Data type for the output.

  • preemph_coeff (float or Tensor/Batch of float, optional, default = 0.97) – Preemphasis coefficient coeff.