hutch_python.load_conf.load_conf¶
-
hutch_python.load_conf.load_conf(conf, hutch_dir=None)¶ Step through the object loading procedure, given a configuration.
The procedure is:
Check the configuration for errors
Display the banner by calling
hutch_bannerUse
hutchkey to createhutch.dbimportable namespace to stash the objects. This will be literallyhutch.dbif hutch is not provided, or the hutch name e.g.mfx.db.Create a
RunEngine,REImport
plan_defaultsand include asp,plansCreate a
daqobject withREregistered.Create a
scan_pvsobject, and leave itdisabled.Use
hutchanddaq_platformkeys to create theelogobject and configure it to match the correct experiment.Use
dbkey to load devices from thehappibeamline database and create ahutch_beampathobject fromlightpathUse
hutchkey to load detector objects from thecamviewerconfiguration file.Use
loadkey to bring up the user’sbeamlinemodulesUse
experimentkey to select the current experimentIf
experimentwas missing, autoselect experiment usinghutchkey
Use current experiment to load experiment objects from questionnaire
Use current experiment to load experiment file
If a conf key is missing, we’ll note it in a
logger.infomessage. If an extra conf entry is found, we’ll note it in alogger.warningmessage. If an automatically selected file is missing, we’ll note it in alogger.infomessage. All other errors will be noted in a logger.error message.- Parameters
conf (
dict) –dictinterpretation of the original yaml filehutch_dir (
Pathorstr, optional) –Pathobject that points to the hutch’s launch directory. This is the directory that includes theexperimentsdirectory and a hutchname directory e.g.mfxIf this is missing, we’ll be unable to write thedb.txtfile, do relative filepath database selection forhappi, or establish a preset positions directory.
- Returns
objs – See the return value of
load- Return type
dict{str: object}