Laboratory#

laboratory

UATAQ Laboratory object.

get_site(SID)

Return site object from config file

Laboratory(config)

Factory class for creating site objects from config file.

Contents#

uataq.laboratory = uataq._laboratory.Laboratory()#

UATAQ Laboratory object.

Built from UATAQ configuration.

uataq.get_site(SID)[source]#

Return site object from config file

Parameters:

SID (str) – The site ID.

Returns:

A site object.

Return type:

sites.Site

class uataq._laboratory.Laboratory(config)[source]#

Factory class for creating site objects from config file.

This class provides methods for creating site objects from a configuration file. The configuration file should contain information about the sites and their instruments.

Attributes:

site_config (str): The path to the site configuration file.

Methods:

get_site(SID): Returns a site object for the specified site ID.

__init__(config)[source]#

Initialize the Laboratory class.

Parameters:

config (str | dict) – The path to the configuration file or a dictionary containing the configuration data.

Raises:

ValueError – If the configuration data is invalid.

get_site(SID)[source]#

Return site object from config file

Parameters:

SID (str) – The site ID.

Returns:

A site object.

Return type:

sites.Site

Raises:
  • ValueError – If the site ID is not found in the configuration file.

  • ValueError – If no instruments are found for the specified site.