pydox.calibration.spec.Workflow

pydox.calibration.spec.Workflow#

class Workflow(*args, **kwargs)[source]#

Base class for one or more calibrations: - Support more than one configuration set - Support more than one method - Support ordered vs sequential vs parallel gain computation

Notes

There is some ambiguity here wrt the use of the word “configuration”: - It may refer to the user-level configuration object that holds all possible library settings and method parameters - But it may also refer to the lower-level unique set of parameters describing a unique calibration computation.

We shall review and fix this.

Warning

A ‘Workflow’ instance (deep)copies the global configuration object internally and will work only with this copy afterward.

Therefore, any changes to the global configuration made after the creation of an instance, won’t have any impact on that ‘Workflow’ instance.

__init__(*args, **kwargs)[source]#
Parameters:
  • name (Optional[str] = None)

  • config (Config) – A specific configuration object to use instead of the current one from pydox.params

Methods

__init__(*args, **kwargs)

create_corrBfile(a_float[, icfg])

fit(data)

Load input data and compute coefficients

flatten_configs()

Return a dictionary with all possible configurations

get_params(*args, **kwargs)

Get configuration parameter(s) for this instance only

load_input_data(data)

Load input data for the flatten list of configurations

plot([icfg, categories, configs_layout])

Show figures from this instance

reset_params(*args, **kwargs)

Reset configuration parameter(s) to instantiation initial value(s)

set_best_fit(icfg)

Set the configuration ID for the best fit

set_params(*args, **kwargs)

Set configuration parameter(s) for this instance only

to_report(a_float[, file_name])

Create a calibration report

uid([icfg])

Unique identifier string for this instance

Attributes

best_fit

ID of the configuration selected as the best fit

coefs

Dictionary of fit coefficients for each configuration

configs

A property to directly access the dictionary of configurations

configs_figures

Dictionary of figures associated with each configurations UID

figures

List of figures associated with this workflow UID

fit_data

Dictionary of fit auxiliary data for each configuration

fitted

Was the instance fitted at least once ?

input_data

Input data for fit

n_configs

Return the number of all possible configurations