darsia.ColorPathInterpolation#

class ColorPathInterpolation(color_path, color_mode, values=None, ignore_spectrum=None)[source]#

Bases: ColorPathFunction

Interpolate concentrations along a colour path from labelled reference values.

Methods

calibrate()

from_dict(data)

Create a ColorPathInterpolation from a dictionary.

load(path)

Load the ColorPathInterpolation from a file.

save(path)

Save the ColorPathInterpolation to a file.

to_dict()

Convert the ColorPathInterpolation to a dictionary representation.

update_model_parameters(parameters[, dofs])

Update the interpolation values of the color path.

Attributes

ignore_spectrum

Spectrum to ignore during parametrization.

color_path

Underlying color path.

color_mode

Color mode used for parametrization.

classmethod from_dict(data)[source]#

Create a ColorPathInterpolation from a dictionary.

Parameters:
datadict

Dictionary representation of the ColorPathInterpolation.

Returns:
ColorPathInterpolation

The created ColorPathInterpolation instance.

classmethod load(path)[source]#

Load the ColorPathInterpolation from a file.

Parameters:
pathPath

The path to the file from which the ColorPathInterpolation should be loaded.

Returns:
ColorPathInterpolation

Loaded ColorPathInterpolation instance.

save(path)[source]#

Save the ColorPathInterpolation to a file.

Parameters:
pathPath

The path to the file where the ColorPathInterpolation should be saved.

to_dict()[source]#

Convert the ColorPathInterpolation to a dictionary representation.

Returns:
dict

Dictionary representation of the ColorPathInterpolation.

update_model_parameters(parameters, dofs=None)[source]#

Update the interpolation values of the color path.

ignore_spectrum#

Spectrum to ignore during parametrization.