Skip to content

profiles

Profiles

An API that allows for storing and loading default stage configurations. Useful if you use AutoGator as a client to connect to several different hardware configurations or setups.

Also provides a way to associate calibration matrices with configurations.

delete_configuration(name)

Deletes a configuration profile and its associated calibration matrix.

Parameters:

Name Type Description Default
name str

The name of the profile to delete.

required

Exceptions:

Type Description
ValueError

If the profile does not exist.

known_configurations()

Returns a list of known hardware configuration profiles.

Returns:

Type Description
List[str]

A list of known profiles.

load_configuration(name)

Loads a configuration from a file.

Parameters:

Name Type Description Default
name str

The name of the profile to load.

required

Exceptions:

Type Description
ValueError

If the profile does not exist.

load_default_configuration()

Loads the default stage configuration.

Exceptions:

Type Description
ValueError

If the default configuration has not been set.

Returns:

Type Description
StageConfiguration

The default stage configuration.

save_configuration(name, configuration)

Saves a configuration to a file.

Names cannot begin with an underscore.

Parameters:

Name Type Description Default
name str

The name of the configuration profile.

required
configuration StageConfiguration

The stage configuration to save.

required

Exceptions:

Type Description
ValueError

If the name is invalid or already in use. To overwrite an existing profile, use update_configuration.

save_default_configuration(name, config)

Creates a named default stage configuration.

Requires a name to enforce uniqueness, but can be loaded again without the name using load_default_configuration.

Parameters:

Name Type Description Default
name str

The name of the configuration profile.

required
config StageConfiguration

The stage configuration to save.

required

Exceptions:

Type Description
ValueError

If the name is invalid.

update_calibration_matrix(name, matrix)

Updates the calibration matrix for a configuration.

Names cannot begin with an underscore. Calibration matrices can only be updated for known configurations (see known_configurations).

Parameters:

Name Type Description Default
name str

The name of the profile to associate the calibration matrix with.

required
matrix ndarray

The calibration matrix to save.

required

Exceptions:

Type Description
ValueError

If the name is invalid or the configuration does not exist.

update_configuration(name, config)

Updates the default stage configuration.

If the name is not in use, it will be saved as a new profile. If the name is in use, the configuration will be overwritten. Names cannot begin with an underscore.

Parameters:

Name Type Description Default
config StageConfiguration

The stage configuration to save.

required

Exceptions:

Type Description
ValueError

If the name is invalid.

Back to top