Parameters (cdl.param)#

The cdl.param module aims at providing all the dataset parameters that are used by the cdl.computation and cdl.core.gui.processor packages.

Those datasets are defined in other modules:

The cdl.param module is thus a convenient way to import all the sets of parameters at once.

As a matter of fact, the following import statement is equivalent to the previous one:

# Original import statement
from cdl.computation.base import MovingAverageParam
from cdl.computation.signal import PolynomialFitParam
from cdl.computation.image.exposure import EqualizeHistParam

# Equivalent import statement
from cdl.param import MovingAverageParam, PolynomialFitParam, EqualizeHistParam

Introduction to DataSet parameters#

The datasets listed in the following sections are used to define the parameters necessary for the various computations and processing operations available in DataLab.

Each dataset is a subclass of guidata.dataset.datatypes.DataSet and thus needs to be instantiated before being used.

Here is a complete example of how to instantiate a dataset and access its parameters with the cdl.param.BinningParam dataset:

class cdl.param.BinningParam[source]

Binning parameters

sx

Cluster size (X). Number of adjacent pixels to be combined together along x-axis. Integer higher than 2. Default: 2.

Type:

guidata.dataset.dataitems.IntItem

sy

Cluster size (Y). Number of adjacent pixels to be combined together along y-axis. Integer higher than 2. Default: 2.

Type:

guidata.dataset.dataitems.IntItem

operation

Single choice from: ‘sum’, ‘average’, ‘median’, ‘min’, ‘max’. Default: ‘sum’.

Type:

guidata.dataset.dataitems.ChoiceItem

dtype_str

Data type. Output image data type. Single choice from: ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘dtype’.

Type:

guidata.dataset.dataitems.ChoiceItem

change_pixel_size

Change pixel size so that overall image size remains the same. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(sx: int, sy: int, operation: str, dtype_str: str, change_pixel_size: bool) cdl.computation.image.BinningParam

Returns a new instance of BinningParam with the fields set to the given values.

Parameters:
  • sx (int) – Cluster size (X). Number of adjacent pixels to be combined together along x-axis. Integer higher than 2. Default: 2.

  • sy (int) – Cluster size (Y). Number of adjacent pixels to be combined together along y-axis. Integer higher than 2. Default: 2.

  • operation (str) – Single choice from: ‘sum’, ‘average’, ‘median’, ‘min’, ‘max’. Default: ‘sum’.

  • dtype_str (str) – Data type. Output image data type. Single choice from: ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘dtype’.

  • change_pixel_size (bool) – Change pixel size so that overall image size remains the same. Default: False.

Returns:

New instance of BinningParam.

Note

To instanciate a new BinningParam dataset, you can use the classmethod BinningParam.create() like this:

BinningParam.create(sx=2, sy=2, operation='sum', dtype_str='dtype', change_pixel_size=False)

You can also first instanciate a default BinningParam and then set the fields like this:

param = BinningParam()
param.sx = 2
param.sy = 2
param.operation = 'sum'
param.dtype_str = 'dtype'
param.change_pixel_size = False

Common parameters#

class cdl.param.ClipParam[source]

Data clipping parameters

lower

Lower clipping value. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

upper

Upper clipping value. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(lower: float, upper: float) cdl.computation.base.ClipParam

Returns a new instance of ClipParam with the fields set to the given values.

Parameters:
  • lower (float) – Lower clipping value. Default: None.

  • upper (float) – Upper clipping value. Default: None.

Returns:

New instance of ClipParam.

class cdl.param.FFTParam[source]

FFT parameters

shift

Shift zero frequency to center. Default: None.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(shift: bool) cdl.computation.base.FFTParam

Returns a new instance of FFTParam with the fields set to the given values.

Parameters:

shift (bool) – Shift zero frequency to center. Default: None.

Returns:

New instance of FFTParam.

class cdl.param.SpectrumParam[source]

Spectrum parameters

log

Default: False.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(log: bool) cdl.computation.base.SpectrumParam

Returns a new instance of SpectrumParam with the fields set to the given values.

Parameters:

log (bool) – Default: False.

Returns:

New instance of SpectrumParam.

class cdl.param.GaussianParam[source]

Gaussian filter parameters

sigma

σ. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(sigma: float) cdl.computation.base.GaussianParam

Returns a new instance of GaussianParam with the fields set to the given values.

Parameters:

sigma (float) – σ. Default: 1.0.

Returns:

New instance of GaussianParam.

class cdl.param.MovingAverageParam[source]

Moving average parameters

n

Size of the moving window. Integer higher than 1. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

mode

Mode of the filter: - ‘reflect’: reflect the data at the boundary - ‘constant’: pad with a constant value - ‘nearest’: pad with the nearest value - ‘mirror’: reflect the data at the boundary with the data itself - ‘wrap’: circular boundary. Single choice from: ‘reflect’, ‘constant’, ‘nearest’, ‘mirror’, ‘wrap’. Default: ‘reflect’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(n: int, mode: str) cdl.computation.base.MovingAverageParam

Returns a new instance of MovingAverageParam with the fields set to the given values.

Parameters:
  • n (int) – Size of the moving window. Integer higher than 1. Default: 3.

  • mode (str) – Mode of the filter: - ‘reflect’: reflect the data at the boundary - ‘constant’: pad with a constant value - ‘nearest’: pad with the nearest value - ‘mirror’: reflect the data at the boundary with the data itself - ‘wrap’: circular boundary. Single choice from: ‘reflect’, ‘constant’, ‘nearest’, ‘mirror’, ‘wrap’. Default: ‘reflect’.

Returns:

New instance of MovingAverageParam.

class cdl.param.MovingMedianParam[source]

Moving median parameters

n

Size of the moving window. Integer higher than 1, odd. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

mode

Mode of the filter: - ‘reflect’: reflect the data at the boundary - ‘constant’: pad with a constant value - ‘nearest’: pad with the nearest value - ‘mirror’: reflect the data at the boundary with the data itself - ‘wrap’: circular boundary. Single choice from: ‘reflect’, ‘constant’, ‘nearest’, ‘mirror’, ‘wrap’. Default: ‘nearest’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(n: int, mode: str) cdl.computation.base.MovingMedianParam

Returns a new instance of MovingMedianParam with the fields set to the given values.

Parameters:
  • n (int) – Size of the moving window. Integer higher than 1, odd. Default: 3.

  • mode (str) – Mode of the filter: - ‘reflect’: reflect the data at the boundary - ‘constant’: pad with a constant value - ‘nearest’: pad with the nearest value - ‘mirror’: reflect the data at the boundary with the data itself - ‘wrap’: circular boundary. Single choice from: ‘reflect’, ‘constant’, ‘nearest’, ‘mirror’, ‘wrap’. Default: ‘nearest’.

Returns:

New instance of MovingMedianParam.

class cdl.param.ROIDataParam[source]

ROI Editor data

roidata

For convenience, this item accepts a 2d numpy array, a list of list of numbers, or none. In the end, the data is converted to a 2d numpy array of integers (if not none). Default: None.

Type:

guidata.dataset.dataitems.FloatArrayItem

singleobj

Whether to extract the roi as a single object or not. Default: None.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(roidata: numpy.ndarray, singleobj: bool) cdl.computation.base.ROIDataParam

Returns a new instance of ROIDataParam with the fields set to the given values.

Parameters:
  • roidata (numpy.ndarray) – For convenience, this item accepts a 2d numpy array, a list of list of numbers, or none. In the end, the data is converted to a 2d numpy array of integers (if not none). Default: None.

  • singleobj (bool) – Whether to extract the roi as a single object or not. Default: None.

Returns:

New instance of ROIDataParam.

property is_empty: bool

Return True if there is no ROI

class cdl.param.ConstantOperationParam[source]
Parameter used to set a constant value to used in operations (sum,

multiplication, …)

value

Constant value. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(value: float) cdl.computation.base.ConstantOperationParam

Returns a new instance of ConstantOperationParam with the fields set to the given values.

Parameters:

value (float) – Constant value. Default: None.

Returns:

New instance of ConstantOperationParam.

Signal parameters#

class cdl.param.DataTypeSParam[source]

Convert signal data type parameters

dtype_str

Destination data type. Output image data type. Single choice from: ‘float32’, ‘float64’, ‘complex128’. Default: ‘float32’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(dtype_str: str) cdl.computation.signal.DataTypeSParam

Returns a new instance of DataTypeSParam with the fields set to the given values.

Parameters:

dtype_str (str) – Destination data type. Output image data type. Single choice from: ‘float32’, ‘float64’, ‘complex128’. Default: ‘float32’.

Returns:

New instance of DataTypeSParam.

class cdl.param.FWHMParam[source]

FWHM parameters

method

Single choice from: ‘zero-crossing’, ‘gauss’, ‘lorentz’, ‘voigt’. Default: ‘zero-crossing’.

Type:

guidata.dataset.dataitems.ChoiceItem

xmin

XMIN. Lower x boundary (empty for no limit, i.e. Start of the signal). Default: None.

Type:

guidata.dataset.dataitems.FloatItem

xmax

XMAX. Upper x boundary (empty for no limit, i.e. End of the signal). Default: None.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, xmin: float, xmax: float) cdl.computation.signal.FWHMParam

Returns a new instance of FWHMParam with the fields set to the given values.

Parameters:
  • method (str) – Single choice from: ‘zero-crossing’, ‘gauss’, ‘lorentz’, ‘voigt’. Default: ‘zero-crossing’.

  • xmin (float) – XMIN. Lower x boundary (empty for no limit, i.e. Start of the signal). Default: None.

  • xmax (float) – XMAX. Upper x boundary (empty for no limit, i.e. End of the signal). Default: None.

Returns:

New instance of FWHMParam.

class cdl.param.NormalizeParam[source]

Normalize parameters

method

Normalize with respect to. Single choice from: ‘maximum’, ‘amplitude’, ‘area’, ‘energy’, ‘rms’. Default: ‘maximum’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(method: str) cdl.computation.base.NormalizeParam

Returns a new instance of NormalizeParam with the fields set to the given values.

Parameters:

method (str) – Normalize with respect to. Single choice from: ‘maximum’, ‘amplitude’, ‘area’, ‘energy’, ‘rms’. Default: ‘maximum’.

Returns:

New instance of NormalizeParam.

class cdl.param.PeakDetectionParam[source]

Peak detection parameters

threshold

Integer between 0 and 100, unit: %. Default: 30.

Type:

guidata.dataset.dataitems.IntItem

min_dist

Minimum distance. Integer higher than 1, unit: points. Default: 1.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(threshold: int, min_dist: int) cdl.computation.signal.PeakDetectionParam

Returns a new instance of PeakDetectionParam with the fields set to the given values.

Parameters:
  • threshold (int) – Integer between 0 and 100, unit: %. Default: 30.

  • min_dist (int) – Minimum distance. Integer higher than 1, unit: points. Default: 1.

Returns:

New instance of PeakDetectionParam.

class cdl.param.PolynomialFitParam[source]

Polynomial fitting parameters

degree

Integer between 1 and 10. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(degree: int) cdl.computation.signal.PolynomialFitParam

Returns a new instance of PolynomialFitParam with the fields set to the given values.

Parameters:

degree (int) – Integer between 1 and 10. Default: 3.

Returns:

New instance of PolynomialFitParam.

class cdl.param.XYCalibrateParam[source]

Signal calibration parameters

axis

Calibrate. Single choice from: ‘x’, ‘y’. Default: ‘y’.

Type:

guidata.dataset.dataitems.ChoiceItem

a

Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

b

Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(axis: str, a: float, b: float) cdl.computation.signal.XYCalibrateParam

Returns a new instance of XYCalibrateParam with the fields set to the given values.

Parameters:
  • axis (str) – Calibrate. Single choice from: ‘x’, ‘y’. Default: ‘y’.

  • a (float) – Default: 1.0.

  • b (float) – Default: 0.0.

Returns:

New instance of XYCalibrateParam.

class cdl.param.InterpolationParam[source]

Interpolation parameters

method

Interpolation method. Single choice from: ‘linear’, ‘spline’, ‘quadratic’, ‘cubic’, ‘barycentric’, ‘pchip’. Default: ‘linear’.

Type:

guidata.dataset.dataitems.ChoiceItem

fill_value

Value to use for points outside the interpolation domain (used only with linear, cubic and pchip methods). Default: None.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, fill_value: float) cdl.computation.signal.InterpolationParam

Returns a new instance of InterpolationParam with the fields set to the given values.

Parameters:
  • method (str) – Interpolation method. Single choice from: ‘linear’, ‘spline’, ‘quadratic’, ‘cubic’, ‘barycentric’, ‘pchip’. Default: ‘linear’.

  • fill_value (float) – Value to use for points outside the interpolation domain (used only with linear, cubic and pchip methods). Default: None.

Returns:

New instance of InterpolationParam.

class cdl.param.ResamplingParam[source]

Resample parameters

method

Interpolation method. Single choice from: ‘linear’, ‘spline’, ‘quadratic’, ‘cubic’, ‘barycentric’, ‘pchip’. Default: ‘linear’.

Type:

guidata.dataset.dataitems.ChoiceItem

fill_value

Value to use for points outside the interpolation domain (used only with linear, cubic and pchip methods). Default: None.

Type:

guidata.dataset.dataitems.FloatItem

xmin

Xmin. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

xmax

Xmax. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

mode

Single choice from: ‘dx’, ‘nbpts’. Default: ‘nbpts’.

Type:

guidata.dataset.dataitems.ChoiceItem

dx

ΔX. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

nbpts

Number of points. Default: None.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(method: str, fill_value: float, xmin: float, xmax: float, mode: str, dx: float, nbpts: int) cdl.computation.signal.ResamplingParam

Returns a new instance of ResamplingParam with the fields set to the given values.

Parameters:
  • method (str) – Interpolation method. Single choice from: ‘linear’, ‘spline’, ‘quadratic’, ‘cubic’, ‘barycentric’, ‘pchip’. Default: ‘linear’.

  • fill_value (float) – Value to use for points outside the interpolation domain (used only with linear, cubic and pchip methods). Default: None.

  • xmin (float) – Xmin. Default: None.

  • xmax (float) – Xmax. Default: None.

  • mode (str) – Single choice from: ‘dx’, ‘nbpts’. Default: ‘nbpts’.

  • dx (float) – ΔX. Default: None.

  • nbpts (int) – Number of points. Default: None.

Returns:

New instance of ResamplingParam.

class cdl.param.DetrendingParam[source]

Detrending parameters

method

Detrending method. Single choice from: ‘linear’, ‘constant’. Default: ‘linear’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(method: str) cdl.computation.signal.DetrendingParam

Returns a new instance of DetrendingParam with the fields set to the given values.

Parameters:

method (str) – Detrending method. Single choice from: ‘linear’, ‘constant’. Default: ‘linear’.

Returns:

New instance of DetrendingParam.

class cdl.param.PowerParam[source]

Power parameters

power

Default: 2.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(power: float) cdl.computation.signal.PowerParam

Returns a new instance of PowerParam with the fields set to the given values.

Parameters:

power (float) – Default: 2.0.

Returns:

New instance of PowerParam.

class cdl.param.WindowingParam[source]

Windowing parameters

method

Single choice from: ‘barthann’, ‘bartlett’, ‘blackman’, ‘blackman-harris’, ‘bohman’, ‘boxcar’, ‘cosine’, ‘exponential’, ‘flat-top’, ‘gaussian’, ‘hamming’, ‘hanning’, ‘kaiser’, ‘lanczos’, ‘nuttall’, ‘parzen’, ‘rectangular’, ‘taylor’, ‘tukey’. Default: ‘hamming’.

Type:

guidata.dataset.dataitems.ChoiceItem

alpha

Shape parameter of the tukey windowing function. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

beta

Shape parameter of the kaiser windowing function. Default: 14.0.

Type:

guidata.dataset.dataitems.FloatItem

sigma

Shape parameter of the gaussian windowing function. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, alpha: float, beta: float, sigma: float) cdl.computation.signal.WindowingParam

Returns a new instance of WindowingParam with the fields set to the given values.

Parameters:
  • method (str) – Single choice from: ‘barthann’, ‘bartlett’, ‘blackman’, ‘blackman-harris’, ‘bohman’, ‘boxcar’, ‘cosine’, ‘exponential’, ‘flat-top’, ‘gaussian’, ‘hamming’, ‘hanning’, ‘kaiser’, ‘lanczos’, ‘nuttall’, ‘parzen’, ‘rectangular’, ‘taylor’, ‘tukey’. Default: ‘hamming’.

  • alpha (float) – Shape parameter of the tukey windowing function. Default: 0.5.

  • beta (float) – Shape parameter of the kaiser windowing function. Default: 14.0.

  • sigma (float) – Shape parameter of the gaussian windowing function. Default: 0.5.

Returns:

New instance of WindowingParam.

class cdl.param.LowPassFilterParam[source]

Low-pass filter parameters

method

Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

Type:

guidata.dataset.dataitems.ChoiceItem

order

Filter order. Integer higher than 1. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

f_cut0

Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

f_cut1

High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

rp

Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

rs

Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, order: int, f_cut0: float, f_cut1: float, rp: float, rs: float) cdl.computation.signal.LowPassFilterParam

Returns a new instance of LowPassFilterParam with the fields set to the given values.

Parameters:
  • method (str) – Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

  • order (int) – Filter order. Integer higher than 1. Default: 3.

  • f_cut0 (float) – Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • f_cut1 (float) – High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • rp (float) – Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

  • rs (float) – Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Returns:

New instance of LowPassFilterParam.

class cdl.param.HighPassFilterParam[source]

High-pass filter parameters

method

Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

Type:

guidata.dataset.dataitems.ChoiceItem

order

Filter order. Integer higher than 1. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

f_cut0

Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

f_cut1

High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

rp

Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

rs

Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, order: int, f_cut0: float, f_cut1: float, rp: float, rs: float) cdl.computation.signal.HighPassFilterParam

Returns a new instance of HighPassFilterParam with the fields set to the given values.

Parameters:
  • method (str) – Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

  • order (int) – Filter order. Integer higher than 1. Default: 3.

  • f_cut0 (float) – Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • f_cut1 (float) – High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • rp (float) – Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

  • rs (float) – Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Returns:

New instance of HighPassFilterParam.

class cdl.param.BandPassFilterParam[source]

Band-pass filter parameters

method

Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

Type:

guidata.dataset.dataitems.ChoiceItem

order

Filter order. Integer higher than 1. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

f_cut0

Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

f_cut1

High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

rp

Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

rs

Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, order: int, f_cut0: float, f_cut1: float, rp: float, rs: float) cdl.computation.signal.BandPassFilterParam

Returns a new instance of BandPassFilterParam with the fields set to the given values.

Parameters:
  • method (str) – Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

  • order (int) – Filter order. Integer higher than 1. Default: 3.

  • f_cut0 (float) – Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • f_cut1 (float) – High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • rp (float) – Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

  • rs (float) – Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Returns:

New instance of BandPassFilterParam.

class cdl.param.BandStopFilterParam[source]

Band-stop filter parameters

method

Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

Type:

guidata.dataset.dataitems.ChoiceItem

order

Filter order. Integer higher than 1. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

f_cut0

Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

f_cut1

High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

rp

Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

rs

Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(method: str, order: int, f_cut0: float, f_cut1: float, rp: float, rs: float) cdl.computation.signal.BandStopFilterParam

Returns a new instance of BandStopFilterParam with the fields set to the given values.

Parameters:
  • method (str) – Filter method. Single choice from: ‘bessel’, ‘butter’, ‘cheby1’, ‘cheby2’, ‘ellip’. Default: ‘bessel’.

  • order (int) – Filter order. Integer higher than 1. Default: 3.

  • f_cut0 (float) – Low cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • f_cut1 (float) – High cutoff frequency. Float higher than 0, non zero, unit: hz. Default: None.

  • rp (float) – Passband ripple. Float higher than 0, non zero, unit: db. Default: 1.

  • rs (float) – Stopband attenuation. Float higher than 0, non zero, unit: db. Default: 1.

Returns:

New instance of BandStopFilterParam.

class cdl.param.DynamicParam[source]

Parameters for dynamic range computation (ENOB, SNR, SINAD, THD, SFDR)

full_scale

Float higher than 0.0, unit: v. Default: 0.16.

Type:

guidata.dataset.dataitems.FloatItem

unit

Unit for sinad. Single choice from: ‘dBc’, ‘dBFS’. Default: ‘dBc’.

Type:

guidata.dataset.dataitems.ChoiceItem

nb_harm

Number of harmonics. Number of harmonics to consider for thd. Integer higher than 1. Default: 5.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(full_scale: float, unit: str, nb_harm: int) cdl.computation.signal.DynamicParam

Returns a new instance of DynamicParam with the fields set to the given values.

Parameters:
  • full_scale (float) – Float higher than 0.0, unit: v. Default: 0.16.

  • unit (str) – Unit for sinad. Single choice from: ‘dBc’, ‘dBFS’. Default: ‘dBc’.

  • nb_harm (int) – Number of harmonics. Number of harmonics to consider for thd. Integer higher than 1. Default: 5.

Returns:

New instance of DynamicParam.

Image parameters#

Base image parameters#

class cdl.param.BinningParam[source]

Binning parameters

sx

Cluster size (X). Number of adjacent pixels to be combined together along x-axis. Integer higher than 2. Default: 2.

Type:

guidata.dataset.dataitems.IntItem

sy

Cluster size (Y). Number of adjacent pixels to be combined together along y-axis. Integer higher than 2. Default: 2.

Type:

guidata.dataset.dataitems.IntItem

operation

Single choice from: ‘sum’, ‘average’, ‘median’, ‘min’, ‘max’. Default: ‘sum’.

Type:

guidata.dataset.dataitems.ChoiceItem

dtype_str

Data type. Output image data type. Single choice from: ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘dtype’.

Type:

guidata.dataset.dataitems.ChoiceItem

change_pixel_size

Change pixel size so that overall image size remains the same. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(sx: int, sy: int, operation: str, dtype_str: str, change_pixel_size: bool) cdl.computation.image.BinningParam

Returns a new instance of BinningParam with the fields set to the given values.

Parameters:
  • sx (int) – Cluster size (X). Number of adjacent pixels to be combined together along x-axis. Integer higher than 2. Default: 2.

  • sy (int) – Cluster size (Y). Number of adjacent pixels to be combined together along y-axis. Integer higher than 2. Default: 2.

  • operation (str) – Single choice from: ‘sum’, ‘average’, ‘median’, ‘min’, ‘max’. Default: ‘sum’.

  • dtype_str (str) – Data type. Output image data type. Single choice from: ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘dtype’.

  • change_pixel_size (bool) – Change pixel size so that overall image size remains the same. Default: False.

Returns:

New instance of BinningParam.

class cdl.param.ButterworthParam[source]

Butterworth filter parameters

cut_off

Cut-off frequency ratio. Cut-off frequency ratio (0.0 - 1.0). Float between 0.0 and 1.0. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

high_pass

If true, apply high-pass filter instead of low-pass. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

order

Order of the butterworth filter. Integer higher than 1. Default: 2.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(cut_off: float, high_pass: bool, order: int) cdl.computation.image.ButterworthParam

Returns a new instance of ButterworthParam with the fields set to the given values.

Parameters:
  • cut_off (float) – Cut-off frequency ratio. Cut-off frequency ratio (0.0 - 1.0). Float between 0.0 and 1.0. Default: 0.5.

  • high_pass (bool) – If true, apply high-pass filter instead of low-pass. Default: False.

  • order (int) – Order of the butterworth filter. Integer higher than 1. Default: 2.

Returns:

New instance of ButterworthParam.

class cdl.param.DataTypeIParam[source]

Convert image data type parameters

dtype_str

Destination data type. Output image data type. Single choice from: ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘float32’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(dtype_str: str) cdl.computation.image.DataTypeIParam

Returns a new instance of DataTypeIParam with the fields set to the given values.

Parameters:

dtype_str (str) – Destination data type. Output image data type. Single choice from: ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘float32’.

Returns:

New instance of DataTypeIParam.

class cdl.param.FlatFieldParam[source]

Flat-field parameters

threshold

Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(threshold: float) cdl.computation.image.FlatFieldParam

Returns a new instance of FlatFieldParam with the fields set to the given values.

Parameters:

threshold (float) – Default: 0.0.

Returns:

New instance of FlatFieldParam.

class cdl.param.GridParam[source]

Grid parameters

direction

Distribute over. Single choice from: ‘col’, ‘row’. Default: ‘col’.

Type:

guidata.dataset.dataitems.ChoiceItem

cols

Columns. Integer, non zero. Default: 1.

Type:

guidata.dataset.dataitems.IntItem

rows

Integer, non zero. Default: 1.

Type:

guidata.dataset.dataitems.IntItem

colspac

Column spacing. Float higher than 0.0. Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

rowspac

Row spacing. Float higher than 0.0. Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(direction: str, cols: int, rows: int, colspac: float, rowspac: float) cdl.computation.image.GridParam

Returns a new instance of GridParam with the fields set to the given values.

Parameters:
  • direction (str) – Distribute over. Single choice from: ‘col’, ‘row’. Default: ‘col’.

  • cols (int) – Columns. Integer, non zero. Default: 1.

  • rows (int) – Integer, non zero. Default: 1.

  • colspac (float) – Column spacing. Float higher than 0.0. Default: 0.0.

  • rowspac (float) – Row spacing. Float higher than 0.0. Default: 0.0.

Returns:

New instance of GridParam.

class cdl.param.HoughCircleParam[source]

Circle Hough transform parameters

min_radius

Radiusmin. Integer higher than 0, non zero, unit: pixels. Default: None.

Type:

guidata.dataset.dataitems.IntItem

max_radius

Radiusmax. Integer higher than 0, non zero, unit: pixels. Default: None.

Type:

guidata.dataset.dataitems.IntItem

min_distance

Minimal distance. Integer higher than 0. Default: None.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(min_radius: int, max_radius: int, min_distance: int) cdl.computation.image.HoughCircleParam

Returns a new instance of HoughCircleParam with the fields set to the given values.

Parameters:
  • min_radius (int) – Radiusmin. Integer higher than 0, non zero, unit: pixels. Default: None.

  • max_radius (int) – Radiusmax. Integer higher than 0, non zero, unit: pixels. Default: None.

  • min_distance (int) – Minimal distance. Integer higher than 0. Default: None.

Returns:

New instance of HoughCircleParam.

class cdl.param.LogP1Param[source]

Log10 parameters

n

Default: None.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(n: float) cdl.computation.image.LogP1Param

Returns a new instance of LogP1Param with the fields set to the given values.

Parameters:

n (float) – Default: None.

Returns:

New instance of LogP1Param.

class cdl.param.LineProfileParam[source]

Horizontal or vertical profile parameters

direction

Single choice from: ‘horizontal’, ‘vertical’. Default: ‘horizontal’.

Type:

guidata.dataset.dataitems.ChoiceItem

row

Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

col

Column. Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(direction: str, row: int, col: int) cdl.computation.image.LineProfileParam

Returns a new instance of LineProfileParam with the fields set to the given values.

Parameters:
  • direction (str) – Single choice from: ‘horizontal’, ‘vertical’. Default: ‘horizontal’.

  • row (int) – Integer higher than 0. Default: 0.

  • col (int) – Column. Integer higher than 0. Default: 0.

Returns:

New instance of LineProfileParam.

class cdl.param.SegmentProfileParam[source]

Segment profile parameters

row1

Start row. Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

col1

Start column. Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

row2

End row. Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

col2

End column. Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(row1: int, col1: int, row2: int, col2: int) cdl.computation.image.SegmentProfileParam

Returns a new instance of SegmentProfileParam with the fields set to the given values.

Parameters:
  • row1 (int) – Start row. Integer higher than 0. Default: 0.

  • col1 (int) – Start column. Integer higher than 0. Default: 0.

  • row2 (int) – End row. Integer higher than 0. Default: 0.

  • col2 (int) – End column. Integer higher than 0. Default: 0.

Returns:

New instance of SegmentProfileParam.

class cdl.param.AverageProfileParam[source]

Average horizontal or vertical profile parameters

direction

Single choice from: ‘horizontal’, ‘vertical’. Default: ‘horizontal’.

Type:

guidata.dataset.dataitems.ChoiceItem

row1

Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

row2

Integer higher than -1. Default: -1.

Type:

guidata.dataset.dataitems.IntItem

col1

Column 1. Integer higher than 0. Default: 0.

Type:

guidata.dataset.dataitems.IntItem

col2

Column 2. Integer higher than -1. Default: -1.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(direction: str, row1: int, row2: int, col1: int, col2: int) cdl.computation.image.AverageProfileParam

Returns a new instance of AverageProfileParam with the fields set to the given values.

Parameters:
  • direction (str) – Single choice from: ‘horizontal’, ‘vertical’. Default: ‘horizontal’.

  • row1 (int) – Integer higher than 0. Default: 0.

  • row2 (int) – Integer higher than -1. Default: -1.

  • col1 (int) – Column 1. Integer higher than 0. Default: 0.

  • col2 (int) – Column 2. Integer higher than -1. Default: -1.

Returns:

New instance of AverageProfileParam.

class cdl.param.RadialProfileParam[source]

Radial profile parameters

center

Center position. Single choice from: ‘centroid’, ‘center’, ‘user’. Default: ‘centroid’.

Type:

guidata.dataset.dataitems.ChoiceItem

x0

XCenter. Float, unit: pixel. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

y0

XCenter. Float, unit: pixel. Default: None.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(center: str, x0: float, y0: float) cdl.computation.image.RadialProfileParam

Returns a new instance of RadialProfileParam with the fields set to the given values.

Parameters:
  • center (str) – Center position. Single choice from: ‘centroid’, ‘center’, ‘user’. Default: ‘centroid’.

  • x0 (float) – XCenter. Float, unit: pixel. Default: None.

  • y0 (float) – XCenter. Float, unit: pixel. Default: None.

Returns:

New instance of RadialProfileParam.

update_from_image(obj: ImageObj) None[source]

Update parameters from image

choice_callback(item, value)[source]

Callback for choice item

class cdl.param.ResizeParam[source]

Resize parameters

zoom

Default: None.

Type:

guidata.dataset.dataitems.FloatItem

mode

Single choice from: ‘constant’, ‘nearest’, ‘reflect’, ‘wrap’. Default: ‘constant’.

Type:

guidata.dataset.dataitems.ChoiceItem

cval

Value used for points outside the boundaries of the input if mode is ‘constant’. Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

prefilter

Default: True.

Type:

guidata.dataset.dataitems.BoolItem

order

Spline interpolation order. Integer between 0 and 5. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(zoom: float, mode: str, cval: float, prefilter: bool, order: int) cdl.computation.image.ResizeParam

Returns a new instance of ResizeParam with the fields set to the given values.

Parameters:
  • zoom (float) – Default: None.

  • mode (str) – Single choice from: ‘constant’, ‘nearest’, ‘reflect’, ‘wrap’. Default: ‘constant’.

  • cval (float) – Value used for points outside the boundaries of the input if mode is ‘constant’. Default: 0.0.

  • prefilter (bool) – Default: True.

  • order (int) – Spline interpolation order. Integer between 0 and 5. Default: 3.

Returns:

New instance of ResizeParam.

class cdl.param.RotateParam[source]

Rotate parameters

angle

Angle (°). Default: None.

Type:

guidata.dataset.dataitems.FloatItem

mode

Single choice from: ‘constant’, ‘nearest’, ‘reflect’, ‘wrap’. Default: ‘constant’.

Type:

guidata.dataset.dataitems.ChoiceItem

cval

Value used for points outside the boundaries of the input if mode is ‘constant’. Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

reshape

Reshape the output array so that the input array is contained completely in the output. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

prefilter

Default: True.

Type:

guidata.dataset.dataitems.BoolItem

order

Spline interpolation order. Integer between 0 and 5. Default: 3.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(angle: float, mode: str, cval: float, reshape: bool, prefilter: bool, order: int) cdl.computation.image.RotateParam

Returns a new instance of RotateParam with the fields set to the given values.

Parameters:
  • angle (float) – Angle (°). Default: None.

  • mode (str) – Single choice from: ‘constant’, ‘nearest’, ‘reflect’, ‘wrap’. Default: ‘constant’.

  • cval (float) – Value used for points outside the boundaries of the input if mode is ‘constant’. Default: 0.0.

  • reshape (bool) – Reshape the output array so that the input array is contained completely in the output. Default: False.

  • prefilter (bool) – Default: True.

  • order (int) – Spline interpolation order. Integer between 0 and 5. Default: 3.

Returns:

New instance of RotateParam.

class cdl.param.ZCalibrateParam[source]

Image linear calibration parameters

a

Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

b

Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(a: float, b: float) cdl.computation.image.ZCalibrateParam

Returns a new instance of ZCalibrateParam with the fields set to the given values.

Parameters:
  • a (float) – Default: 1.0.

  • b (float) – Default: 0.0.

Returns:

New instance of ZCalibrateParam.

Threshold parameters#

class cdl.param.ThresholdParam[source]

Histogram threshold parameters

method

Threshold method. Single choice from: ‘manual’, ‘isodata’, ‘li’, ‘mean’, ‘minimum’, ‘otsu’, ‘triangle’, ‘yen’. Default: ‘manual’.

Type:

guidata.dataset.dataitems.ChoiceItem

bins

Number of bins. Integer higher than 1. Default: 256.

Type:

guidata.dataset.dataitems.IntItem

value

Threshold value. Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

operation

Single choice from: ‘>’, ‘<’. Default: ‘>’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(method: str, bins: int, value: float, operation: str) cdl.computation.image.threshold.ThresholdParam

Returns a new instance of ThresholdParam with the fields set to the given values.

Parameters:
  • method (str) – Threshold method. Single choice from: ‘manual’, ‘isodata’, ‘li’, ‘mean’, ‘minimum’, ‘otsu’, ‘triangle’, ‘yen’. Default: ‘manual’.

  • bins (int) – Number of bins. Integer higher than 1. Default: 256.

  • value (float) – Threshold value. Default: 0.0.

  • operation (str) – Single choice from: ‘>’, ‘<’. Default: ‘>’.

Returns:

New instance of ThresholdParam.

Exposure correction parameters#

class cdl.param.AdjustGammaParam[source]

Gamma adjustment parameters

gamma

Gamma correction factor (higher values give more contrast). Float higher than 0.0. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

gain

Gain factor (higher values give more contrast). Float higher than 0.0. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(gamma: float, gain: float) cdl.computation.image.exposure.AdjustGammaParam

Returns a new instance of AdjustGammaParam with the fields set to the given values.

Parameters:
  • gamma (float) – Gamma correction factor (higher values give more contrast). Float higher than 0.0. Default: 1.0.

  • gain (float) – Gain factor (higher values give more contrast). Float higher than 0.0. Default: 1.0.

Returns:

New instance of AdjustGammaParam.

class cdl.param.AdjustLogParam[source]

Logarithmic adjustment parameters

gain

Gain factor (higher values give more contrast). Float higher than 0.0. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

inv

If true, apply inverse logarithmic transformation. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(gain: float, inv: bool) cdl.computation.image.exposure.AdjustLogParam

Returns a new instance of AdjustLogParam with the fields set to the given values.

Parameters:
  • gain (float) – Gain factor (higher values give more contrast). Float higher than 0.0. Default: 1.0.

  • inv (bool) – If true, apply inverse logarithmic transformation. Default: False.

Returns:

New instance of AdjustLogParam.

class cdl.param.AdjustSigmoidParam[source]

Sigmoid adjustment parameters

cutoff

Cutoff value (higher values give more contrast). Float between 0.0 and 1.0. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

gain

Gain factor (higher values give more contrast). Float higher than 0.0. Default: 10.0.

Type:

guidata.dataset.dataitems.FloatItem

inv

If true, apply inverse sigmoid transformation. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(cutoff: float, gain: float, inv: bool) cdl.computation.image.exposure.AdjustSigmoidParam

Returns a new instance of AdjustSigmoidParam with the fields set to the given values.

Parameters:
  • cutoff (float) – Cutoff value (higher values give more contrast). Float between 0.0 and 1.0. Default: 0.5.

  • gain (float) – Gain factor (higher values give more contrast). Float higher than 0.0. Default: 10.0.

  • inv (bool) – If true, apply inverse sigmoid transformation. Default: False.

Returns:

New instance of AdjustSigmoidParam.

class cdl.param.EqualizeAdaptHistParam[source]

Adaptive histogram equalization parameters

nbins

Number of bins. Number of bins for image histogram. Integer higher than 1. Default: 256.

Type:

guidata.dataset.dataitems.IntItem

clip_limit

Clipping limit. Clipping limit (higher values give more contrast). Float between 0.0 and 1.0. Default: 0.01.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(nbins: int, clip_limit: float) cdl.computation.image.exposure.EqualizeAdaptHistParam

Returns a new instance of EqualizeAdaptHistParam with the fields set to the given values.

Parameters:
  • nbins (int) – Number of bins. Number of bins for image histogram. Integer higher than 1. Default: 256.

  • clip_limit (float) – Clipping limit. Clipping limit (higher values give more contrast). Float between 0.0 and 1.0. Default: 0.01.

Returns:

New instance of EqualizeAdaptHistParam.

class cdl.param.EqualizeHistParam[source]

Histogram equalization parameters

nbins

Number of bins. Number of bins for image histogram. Integer higher than 1. Default: 256.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(nbins: int) cdl.computation.image.exposure.EqualizeHistParam

Returns a new instance of EqualizeHistParam with the fields set to the given values.

Parameters:

nbins (int) – Number of bins. Number of bins for image histogram. Integer higher than 1. Default: 256.

Returns:

New instance of EqualizeHistParam.

class cdl.param.RescaleIntensityParam[source]

Intensity rescaling parameters

in_range

Input range. Min and max intensity values of input image (‘image’ refers to input image min/max levels, ‘dtype’ refers to input image data type range). Single choice from: ‘image’, ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘image’.

Type:

guidata.dataset.dataitems.ChoiceItem

out_range

Output range. Min and max intensity values of output image (‘image’ refers to input image min/max levels, ‘dtype’ refers to input image data type range).. Single choice from: ‘image’, ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘dtype’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(in_range: str, out_range: str) cdl.computation.image.exposure.RescaleIntensityParam

Returns a new instance of RescaleIntensityParam with the fields set to the given values.

Parameters:
  • in_range (str) – Input range. Min and max intensity values of input image (‘image’ refers to input image min/max levels, ‘dtype’ refers to input image data type range). Single choice from: ‘image’, ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘image’.

  • out_range (str) – Output range. Min and max intensity values of output image (‘image’ refers to input image min/max levels, ‘dtype’ refers to input image data type range).. Single choice from: ‘image’, ‘dtype’, ‘float32’, ‘float64’, ‘complex128’, ‘int32’, ‘int16’, ‘uint16’, ‘uint8’. Default: ‘dtype’.

Returns:

New instance of RescaleIntensityParam.

Restoration parameters#

class cdl.param.DenoiseBilateralParam[source]

Bilateral filter denoising parameters

sigma_spatial

σspatial. Standard deviation for range distance. A larger value results in averaging of pixels with larger spatial differences. Float higher than 0, non zero, unit: pixels. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

mode

Single choice from: ‘constant’, ‘edge’, ‘symmetric’, ‘reflect’, ‘wrap’. Default: ‘constant’.

Type:

guidata.dataset.dataitems.ChoiceItem

cval

Used in conjunction with mode ‘constant’, the value outside the image boundaries. Default: 0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(sigma_spatial: float, mode: str, cval: float) cdl.computation.image.restoration.DenoiseBilateralParam

Returns a new instance of DenoiseBilateralParam with the fields set to the given values.

Parameters:
  • sigma_spatial (float) – σspatial. Standard deviation for range distance. A larger value results in averaging of pixels with larger spatial differences. Float higher than 0, non zero, unit: pixels. Default: 1.0.

  • mode (str) – Single choice from: ‘constant’, ‘edge’, ‘symmetric’, ‘reflect’, ‘wrap’. Default: ‘constant’.

  • cval (float) – Used in conjunction with mode ‘constant’, the value outside the image boundaries. Default: 0.

Returns:

New instance of DenoiseBilateralParam.

class cdl.param.DenoiseTVParam[source]

Total Variation denoising parameters

weight

Denoising weight. The greater weight, the more denoising (at the expense of fidelity to input). Float higher than 0, non zero. Default: 0.1.

Type:

guidata.dataset.dataitems.FloatItem

eps

Epsilon. Relative difference of the value of the cost function that determines the stop criterion. The algorithm stops when: (e_(n-1) - e_n) < eps * e_0. Float higher than 0, non zero. Default: 0.0002.

Type:

guidata.dataset.dataitems.FloatItem

max_num_iter

Max. iterations. Maximal number of iterations used for the optimization. Integer higher than 0, non zero. Default: 200.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(weight: float, eps: float, max_num_iter: int) cdl.computation.image.restoration.DenoiseTVParam

Returns a new instance of DenoiseTVParam with the fields set to the given values.

Parameters:
  • weight (float) – Denoising weight. The greater weight, the more denoising (at the expense of fidelity to input). Float higher than 0, non zero. Default: 0.1.

  • eps (float) – Epsilon. Relative difference of the value of the cost function that determines the stop criterion. The algorithm stops when: (e_(n-1) - e_n) < eps * e_0. Float higher than 0, non zero. Default: 0.0002.

  • max_num_iter (int) – Max. iterations. Maximal number of iterations used for the optimization. Integer higher than 0, non zero. Default: 200.

Returns:

New instance of DenoiseTVParam.

class cdl.param.DenoiseWaveletParam[source]

Wavelet denoising parameters

wavelet

Single choice from: ‘bior1.1’, ‘bior1.3’, ‘bior1.5’, ‘bior2.2’, ‘bior2.4’, ‘bior2.6’, ‘bior2.8’, ‘bior3.1’, ‘bior3.3’, ‘bior3.5’, ‘bior3.7’, ‘bior3.9’, ‘bior4.4’, ‘bior5.5’, ‘bior6.8’, ‘cgau1’, ‘cgau2’, ‘cgau3’, ‘cgau4’, ‘cgau5’, ‘cgau6’, ‘cgau7’, ‘cgau8’, ‘cmor’, ‘coif1’, ‘coif2’, ‘coif3’, ‘coif4’, ‘coif5’, ‘coif6’, ‘coif7’, ‘coif8’, ‘coif9’, ‘coif10’, ‘coif11’, ‘coif12’, ‘coif13’, ‘coif14’, ‘coif15’, ‘coif16’, ‘coif17’, ‘db1’, ‘db2’, ‘db3’, ‘db4’, ‘db5’, ‘db6’, ‘db7’, ‘db8’, ‘db9’, ‘db10’, ‘db11’, ‘db12’, ‘db13’, ‘db14’, ‘db15’, ‘db16’, ‘db17’, ‘db18’, ‘db19’, ‘db20’, ‘db21’, ‘db22’, ‘db23’, ‘db24’, ‘db25’, ‘db26’, ‘db27’, ‘db28’, ‘db29’, ‘db30’, ‘db31’, ‘db32’, ‘db33’, ‘db34’, ‘db35’, ‘db36’, ‘db37’, ‘db38’, ‘dmey’, ‘fbsp’, ‘gaus1’, ‘gaus2’, ‘gaus3’, ‘gaus4’, ‘gaus5’, ‘gaus6’, ‘gaus7’, ‘gaus8’, ‘haar’, ‘mexh’, ‘morl’, ‘rbio1.1’, ‘rbio1.3’, ‘rbio1.5’, ‘rbio2.2’, ‘rbio2.4’, ‘rbio2.6’, ‘rbio2.8’, ‘rbio3.1’, ‘rbio3.3’, ‘rbio3.5’, ‘rbio3.7’, ‘rbio3.9’, ‘rbio4.4’, ‘rbio5.5’, ‘rbio6.8’, ‘shan’, ‘sym2’, ‘sym3’, ‘sym4’, ‘sym5’, ‘sym6’, ‘sym7’, ‘sym8’, ‘sym9’, ‘sym10’, ‘sym11’, ‘sym12’, ‘sym13’, ‘sym14’, ‘sym15’, ‘sym16’, ‘sym17’, ‘sym18’, ‘sym19’, ‘sym20’. Default: ‘sym9’.

Type:

guidata.dataset.dataitems.ChoiceItem

mode

Single choice from: ‘soft’, ‘hard’. Default: ‘soft’.

Type:

guidata.dataset.dataitems.ChoiceItem

method

Single choice from: ‘BayesShrink’, ‘VisuShrink’. Default: ‘VisuShrink’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(wavelet: str, mode: str, method: str) cdl.computation.image.restoration.DenoiseWaveletParam

Returns a new instance of DenoiseWaveletParam with the fields set to the given values.

Parameters:
  • wavelet (str) – Single choice from: ‘bior1.1’, ‘bior1.3’, ‘bior1.5’, ‘bior2.2’, ‘bior2.4’, ‘bior2.6’, ‘bior2.8’, ‘bior3.1’, ‘bior3.3’, ‘bior3.5’, ‘bior3.7’, ‘bior3.9’, ‘bior4.4’, ‘bior5.5’, ‘bior6.8’, ‘cgau1’, ‘cgau2’, ‘cgau3’, ‘cgau4’, ‘cgau5’, ‘cgau6’, ‘cgau7’, ‘cgau8’, ‘cmor’, ‘coif1’, ‘coif2’, ‘coif3’, ‘coif4’, ‘coif5’, ‘coif6’, ‘coif7’, ‘coif8’, ‘coif9’, ‘coif10’, ‘coif11’, ‘coif12’, ‘coif13’, ‘coif14’, ‘coif15’, ‘coif16’, ‘coif17’, ‘db1’, ‘db2’, ‘db3’, ‘db4’, ‘db5’, ‘db6’, ‘db7’, ‘db8’, ‘db9’, ‘db10’, ‘db11’, ‘db12’, ‘db13’, ‘db14’, ‘db15’, ‘db16’, ‘db17’, ‘db18’, ‘db19’, ‘db20’, ‘db21’, ‘db22’, ‘db23’, ‘db24’, ‘db25’, ‘db26’, ‘db27’, ‘db28’, ‘db29’, ‘db30’, ‘db31’, ‘db32’, ‘db33’, ‘db34’, ‘db35’, ‘db36’, ‘db37’, ‘db38’, ‘dmey’, ‘fbsp’, ‘gaus1’, ‘gaus2’, ‘gaus3’, ‘gaus4’, ‘gaus5’, ‘gaus6’, ‘gaus7’, ‘gaus8’, ‘haar’, ‘mexh’, ‘morl’, ‘rbio1.1’, ‘rbio1.3’, ‘rbio1.5’, ‘rbio2.2’, ‘rbio2.4’, ‘rbio2.6’, ‘rbio2.8’, ‘rbio3.1’, ‘rbio3.3’, ‘rbio3.5’, ‘rbio3.7’, ‘rbio3.9’, ‘rbio4.4’, ‘rbio5.5’, ‘rbio6.8’, ‘shan’, ‘sym2’, ‘sym3’, ‘sym4’, ‘sym5’, ‘sym6’, ‘sym7’, ‘sym8’, ‘sym9’, ‘sym10’, ‘sym11’, ‘sym12’, ‘sym13’, ‘sym14’, ‘sym15’, ‘sym16’, ‘sym17’, ‘sym18’, ‘sym19’, ‘sym20’. Default: ‘sym9’.

  • mode (str) – Single choice from: ‘soft’, ‘hard’. Default: ‘soft’.

  • method (str) – Single choice from: ‘BayesShrink’, ‘VisuShrink’. Default: ‘VisuShrink’.

Returns:

New instance of DenoiseWaveletParam.

Morphological parameters#

class cdl.param.MorphologyParam[source]

White Top-Hat parameters

radius

Footprint (disk) radius. Integer higher than 1. Default: 1.

Type:

guidata.dataset.dataitems.IntItem

classmethod create(radius: int) cdl.computation.image.morphology.MorphologyParam

Returns a new instance of MorphologyParam with the fields set to the given values.

Parameters:

radius (int) – Footprint (disk) radius. Integer higher than 1. Default: 1.

Returns:

New instance of MorphologyParam.

Edge detection parameters#

class cdl.param.CannyParam[source]

Canny filter parameters

sigma

Standard deviation of the gaussian filter. Float higher than 0, non zero, unit: pixels. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

low_threshold

Lower bound for hysteresis thresholding (linking edges). Float higher than 0. Default: 0.1.

Type:

guidata.dataset.dataitems.FloatItem

high_threshold

Upper bound for hysteresis thresholding (linking edges). Float higher than 0. Default: 0.9.

Type:

guidata.dataset.dataitems.FloatItem

use_quantiles

If true then treat low_threshold and high_threshold as quantiles of the edge magnitude image, rather than absolute edge magnitude values. If true then the thresholds must be in the range [0, 1]. Default: True.

Type:

guidata.dataset.dataitems.BoolItem

mode

Single choice from: ‘reflect’, ‘constant’, ‘nearest’, ‘mirror’, ‘wrap’. Default: ‘constant’.

Type:

guidata.dataset.dataitems.ChoiceItem

cval

Value to fill past edges of input if mode is constant. Default: 0.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(sigma: float, low_threshold: float, high_threshold: float, use_quantiles: bool, mode: str, cval: float) cdl.computation.image.edges.CannyParam

Returns a new instance of CannyParam with the fields set to the given values.

Parameters:
  • sigma (float) – Standard deviation of the gaussian filter. Float higher than 0, non zero, unit: pixels. Default: 1.0.

  • low_threshold (float) – Lower bound for hysteresis thresholding (linking edges). Float higher than 0. Default: 0.1.

  • high_threshold (float) – Upper bound for hysteresis thresholding (linking edges). Float higher than 0. Default: 0.9.

  • use_quantiles (bool) – If true then treat low_threshold and high_threshold as quantiles of the edge magnitude image, rather than absolute edge magnitude values. If true then the thresholds must be in the range [0, 1]. Default: True.

  • mode (str) – Single choice from: ‘reflect’, ‘constant’, ‘nearest’, ‘mirror’, ‘wrap’. Default: ‘constant’.

  • cval (float) – Value to fill past edges of input if mode is constant. Default: 0.0.

Returns:

New instance of CannyParam.

Detection parameters#

class cdl.param.BlobDOGParam[source]

Blob detection using Difference of Gaussian method

min_sigma

σmin. The minimum standard deviation for gaussian kernel. Keep this low to detect smaller blobs. Float higher than 0, non zero, unit: pixels. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

max_sigma

σmax. The maximum standard deviation for gaussian kernel. Keep this high to detect larger blobs. Float higher than 0, non zero, unit: pixels. Default: 30.0.

Type:

guidata.dataset.dataitems.FloatItem

threshold_rel

Relative threshold. Minimum intensity of blobs. Float between 0.0 and 1.0. Default: 0.2.

Type:

guidata.dataset.dataitems.FloatItem

overlap

If two blobs overlap by a fraction greater than this value, the smaller blob is eliminated. Float between 0.0 and 1.0. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

exclude_border

If true, exclude blobs from the border of the image. Default: True.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(min_sigma: float, max_sigma: float, threshold_rel: float, overlap: float, exclude_border: bool) cdl.computation.image.detection.BlobDOGParam

Returns a new instance of BlobDOGParam with the fields set to the given values.

Parameters:
  • min_sigma (float) – σmin. The minimum standard deviation for gaussian kernel. Keep this low to detect smaller blobs. Float higher than 0, non zero, unit: pixels. Default: 1.0.

  • max_sigma (float) – σmax. The maximum standard deviation for gaussian kernel. Keep this high to detect larger blobs. Float higher than 0, non zero, unit: pixels. Default: 30.0.

  • threshold_rel (float) – Relative threshold. Minimum intensity of blobs. Float between 0.0 and 1.0. Default: 0.2.

  • overlap (float) – If two blobs overlap by a fraction greater than this value, the smaller blob is eliminated. Float between 0.0 and 1.0. Default: 0.5.

  • exclude_border (bool) – If true, exclude blobs from the border of the image. Default: True.

Returns:

New instance of BlobDOGParam.

class cdl.param.BlobDOHParam[source]

Blob detection using Determinant of Hessian method

min_sigma

σmin. The minimum standard deviation for gaussian kernel. Keep this low to detect smaller blobs. Float higher than 0, non zero, unit: pixels. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

max_sigma

σmax. The maximum standard deviation for gaussian kernel. Keep this high to detect larger blobs. Float higher than 0, non zero, unit: pixels. Default: 30.0.

Type:

guidata.dataset.dataitems.FloatItem

threshold_rel

Relative threshold. Minimum intensity of blobs. Float between 0.0 and 1.0. Default: 0.2.

Type:

guidata.dataset.dataitems.FloatItem

overlap

If two blobs overlap by a fraction greater than this value, the smaller blob is eliminated. Float between 0.0 and 1.0. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

log_scale

If set intermediate values of standard deviations are interpolated using a logarithmic scale to the base 10. If not, linear interpolation is used. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(min_sigma: float, max_sigma: float, threshold_rel: float, overlap: float, log_scale: bool) cdl.computation.image.detection.BlobDOHParam

Returns a new instance of BlobDOHParam with the fields set to the given values.

Parameters:
  • min_sigma (float) – σmin. The minimum standard deviation for gaussian kernel. Keep this low to detect smaller blobs. Float higher than 0, non zero, unit: pixels. Default: 1.0.

  • max_sigma (float) – σmax. The maximum standard deviation for gaussian kernel. Keep this high to detect larger blobs. Float higher than 0, non zero, unit: pixels. Default: 30.0.

  • threshold_rel (float) – Relative threshold. Minimum intensity of blobs. Float between 0.0 and 1.0. Default: 0.2.

  • overlap (float) – If two blobs overlap by a fraction greater than this value, the smaller blob is eliminated. Float between 0.0 and 1.0. Default: 0.5.

  • log_scale (bool) – If set intermediate values of standard deviations are interpolated using a logarithmic scale to the base 10. If not, linear interpolation is used. Default: False.

Returns:

New instance of BlobDOHParam.

class cdl.param.BlobLOGParam[source]

Blob detection using Laplacian of Gaussian method

min_sigma

σmin. The minimum standard deviation for gaussian kernel. Keep this low to detect smaller blobs. Float higher than 0, non zero, unit: pixels. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

max_sigma

σmax. The maximum standard deviation for gaussian kernel. Keep this high to detect larger blobs. Float higher than 0, non zero, unit: pixels. Default: 30.0.

Type:

guidata.dataset.dataitems.FloatItem

threshold_rel

Relative threshold. Minimum intensity of blobs. Float between 0.0 and 1.0. Default: 0.2.

Type:

guidata.dataset.dataitems.FloatItem

overlap

If two blobs overlap by a fraction greater than this value, the smaller blob is eliminated. Float between 0.0 and 1.0. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

log_scale

If set intermediate values of standard deviations are interpolated using a logarithmic scale to the base 10. If not, linear interpolation is used. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

exclude_border

If true, exclude blobs from the border of the image. Default: True.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(min_sigma: float, max_sigma: float, threshold_rel: float, overlap: float, log_scale: bool, exclude_border: bool) cdl.computation.image.detection.BlobLOGParam

Returns a new instance of BlobLOGParam with the fields set to the given values.

Parameters:
  • min_sigma (float) – σmin. The minimum standard deviation for gaussian kernel. Keep this low to detect smaller blobs. Float higher than 0, non zero, unit: pixels. Default: 1.0.

  • max_sigma (float) – σmax. The maximum standard deviation for gaussian kernel. Keep this high to detect larger blobs. Float higher than 0, non zero, unit: pixels. Default: 30.0.

  • threshold_rel (float) – Relative threshold. Minimum intensity of blobs. Float between 0.0 and 1.0. Default: 0.2.

  • overlap (float) – If two blobs overlap by a fraction greater than this value, the smaller blob is eliminated. Float between 0.0 and 1.0. Default: 0.5.

  • log_scale (bool) – If set intermediate values of standard deviations are interpolated using a logarithmic scale to the base 10. If not, linear interpolation is used. Default: False.

  • exclude_border (bool) – If true, exclude blobs from the border of the image. Default: True.

Returns:

New instance of BlobLOGParam.

class cdl.param.BlobOpenCVParam[source]

Blob detection using OpenCV

min_threshold

Min. threshold. The minimum threshold between local maxima and minima. This parameter does not affect the quality of the blobs, only the quantity. Lower thresholds result in larger numbers of blobs. Float higher than 0.0. Default: 10.0.

Type:

guidata.dataset.dataitems.FloatItem

max_threshold

Max. threshold. The maximum threshold between local maxima and minima. This parameter does not affect the quality of the blobs, only the quantity. Lower thresholds result in larger numbers of blobs. Float higher than 0.0. Default: 200.0.

Type:

guidata.dataset.dataitems.FloatItem

min_repeatability

Min. repeatability. The minimum number of times a blob needs to be detected in a sequence of images to be considered valid. Integer higher than 1. Default: 2.

Type:

guidata.dataset.dataitems.IntItem

min_dist_between_blobs

Min. distance between blobs. The minimum distance between two blobs. If blobs are found closer together than this distance, the smaller blob is removed. Float higher than 0.0, non zero. Default: 10.0.

Type:

guidata.dataset.dataitems.FloatItem

filter_by_color

If true, the image is filtered by color instead of intensity. Default: True.

Type:

guidata.dataset.dataitems.BoolItem

blob_color

The color of the blobs to detect (0 for dark blobs, 255 for light blobs). Default: 0.

Type:

guidata.dataset.dataitems.IntItem

filter_by_area

If true, the image is filtered by blob area. Default: True.

Type:

guidata.dataset.dataitems.BoolItem

min_area

Min. area. The minimum blob area. Float higher than 0.0. Default: 25.0.

Type:

guidata.dataset.dataitems.FloatItem

max_area

Max. area. The maximum blob area. Float higher than 0.0. Default: 500.0.

Type:

guidata.dataset.dataitems.FloatItem

filter_by_circularity

If true, the image is filtered by blob circularity. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

min_circularity

Min. circularity. The minimum circularity of the blobs. Float between 0.0 and 1.0. Default: 0.8.

Type:

guidata.dataset.dataitems.FloatItem

max_circularity

Max. circularity. The maximum circularity of the blobs. Float between 0.0 and 1.0. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

filter_by_inertia

If true, the image is filtered by blob inertia. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

min_inertia_ratio

Min. inertia ratio. The minimum inertia ratio of the blobs. Float between 0.0 and 1.0. Default: 0.6.

Type:

guidata.dataset.dataitems.FloatItem

max_inertia_ratio

Max. inertia ratio. The maximum inertia ratio of the blobs. Float between 0.0 and 1.0. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

filter_by_convexity

If true, the image is filtered by blob convexity. Default: False.

Type:

guidata.dataset.dataitems.BoolItem

min_convexity

Min. convexity. The minimum convexity of the blobs. Float between 0.0 and 1.0. Default: 0.8.

Type:

guidata.dataset.dataitems.FloatItem

max_convexity

Max. convexity. The maximum convexity of the blobs. Float between 0.0 and 1.0. Default: 1.0.

Type:

guidata.dataset.dataitems.FloatItem

classmethod create(min_threshold: float, max_threshold: float, min_repeatability: int, min_dist_between_blobs: float, filter_by_color: bool, blob_color: int, filter_by_area: bool, min_area: float, max_area: float, filter_by_circularity: bool, min_circularity: float, max_circularity: float, filter_by_inertia: bool, min_inertia_ratio: float, max_inertia_ratio: float, filter_by_convexity: bool, min_convexity: float, max_convexity: float) cdl.computation.image.detection.BlobOpenCVParam

Returns a new instance of BlobOpenCVParam with the fields set to the given values.

Parameters:
  • min_threshold (float) – Min. threshold. The minimum threshold between local maxima and minima. This parameter does not affect the quality of the blobs, only the quantity. Lower thresholds result in larger numbers of blobs. Float higher than 0.0. Default: 10.0.

  • max_threshold (float) – Max. threshold. The maximum threshold between local maxima and minima. This parameter does not affect the quality of the blobs, only the quantity. Lower thresholds result in larger numbers of blobs. Float higher than 0.0. Default: 200.0.

  • min_repeatability (int) – Min. repeatability. The minimum number of times a blob needs to be detected in a sequence of images to be considered valid. Integer higher than 1. Default: 2.

  • min_dist_between_blobs (float) – Min. distance between blobs. The minimum distance between two blobs. If blobs are found closer together than this distance, the smaller blob is removed. Float higher than 0.0, non zero. Default: 10.0.

  • filter_by_color (bool) – If true, the image is filtered by color instead of intensity. Default: True.

  • blob_color (int) – The color of the blobs to detect (0 for dark blobs, 255 for light blobs). Default: 0.

  • filter_by_area (bool) – If true, the image is filtered by blob area. Default: True.

  • min_area (float) – Min. area. The minimum blob area. Float higher than 0.0. Default: 25.0.

  • max_area (float) – Max. area. The maximum blob area. Float higher than 0.0. Default: 500.0.

  • filter_by_circularity (bool) – If true, the image is filtered by blob circularity. Default: False.

  • min_circularity (float) – Min. circularity. The minimum circularity of the blobs. Float between 0.0 and 1.0. Default: 0.8.

  • max_circularity (float) – Max. circularity. The maximum circularity of the blobs. Float between 0.0 and 1.0. Default: 1.0.

  • filter_by_inertia (bool) – If true, the image is filtered by blob inertia. Default: False.

  • min_inertia_ratio (float) – Min. inertia ratio. The minimum inertia ratio of the blobs. Float between 0.0 and 1.0. Default: 0.6.

  • max_inertia_ratio (float) – Max. inertia ratio. The maximum inertia ratio of the blobs. Float between 0.0 and 1.0. Default: 1.0.

  • filter_by_convexity (bool) – If true, the image is filtered by blob convexity. Default: False.

  • min_convexity (float) – Min. convexity. The minimum convexity of the blobs. Float between 0.0 and 1.0. Default: 0.8.

  • max_convexity (float) – Max. convexity. The maximum convexity of the blobs. Float between 0.0 and 1.0. Default: 1.0.

Returns:

New instance of BlobOpenCVParam.

class cdl.param.ContourShapeParam[source]

Contour shape parameters

threshold

Relative threshold. Detection threshold, relative to difference between data maximum and minimum. Float between 0.1 and 0.9. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

shape

Single choice from: ‘ellipse’, ‘circle’, ‘polygon’. Default: ‘ellipse’.

Type:

guidata.dataset.dataitems.ChoiceItem

classmethod create(threshold: float, shape: str) cdl.computation.image.detection.ContourShapeParam

Returns a new instance of ContourShapeParam with the fields set to the given values.

Parameters:
  • threshold (float) – Relative threshold. Detection threshold, relative to difference between data maximum and minimum. Float between 0.1 and 0.9. Default: 0.5.

  • shape (str) – Single choice from: ‘ellipse’, ‘circle’, ‘polygon’. Default: ‘ellipse’.

Returns:

New instance of ContourShapeParam.

class cdl.param.Peak2DDetectionParam[source]

Peak detection parameters

threshold

Relative threshold. Detection threshold, relative to difference between data maximum and minimum. Float between 0.1 and 0.9. Default: 0.5.

Type:

guidata.dataset.dataitems.FloatItem

size

Neighborhoods size. Size of the sliding window used in maximum/minimum filtering algorithm. Integer higher than 1, unit: pixels. Default: 10.

Type:

guidata.dataset.dataitems.IntItem

create_rois

Default: True.

Type:

guidata.dataset.dataitems.BoolItem

classmethod create(threshold: float, size: int, create_rois: bool) cdl.computation.image.detection.Peak2DDetectionParam

Returns a new instance of Peak2DDetectionParam with the fields set to the given values.

Parameters:
  • threshold (float) – Relative threshold. Detection threshold, relative to difference between data maximum and minimum. Float between 0.1 and 0.9. Default: 0.5.

  • size (int) – Neighborhoods size. Size of the sliding window used in maximum/minimum filtering algorithm. Integer higher than 1, unit: pixels. Default: 10.

  • create_rois (bool) – Default: True.

Returns:

New instance of Peak2DDetectionParam.