deepof.utils.smooth_boolean_array

deepof.utils.smooth_boolean_array(a: array, scale: int = 1) array

Return a boolean array in which isolated appearances of a feature are smoothed.

Parameters:
  • a (numpy.ndarray) – Boolean instances.

  • scale (int) – Kleinberg scale parameter. Higher values result in stricter smoothing.

Returns:

Smoothened boolean instances.

Return type:

a (numpy.ndarray)