Clip#

class deeptrack.math.Clip(min: float | Callable[[...], float] = -inf, max: float | Callable[[...], float] = inf, **kwargs)#

Bases: Feature

Clip the input within a minimum and a maximum value.

Parameters#

minfloat

Clip the input to be larger than this value.

maxfloat

Clip the input to be smaller than this value.

Methods Summary

get(image[, min, max])

Transform an image [abstract method].

Methods Documentation

get(image, min=None, max=None, **kwargs)#

Transform an image [abstract method].

Abstract method that defines how the feature transforms the input. The current value of all properties will be passed as keyword arguments.

Parameters#

image‘Image’ or List[‘Image’]

The Image or list of images to transform.

**kwargsDict[str, Any]

The current value of all properties in properties as well as any global arguments.

Returns#

‘Image’ or List[‘Image’]

The transformed image or list of images.

Raises#

NotImplementedError

Must be overridden by subclasses.