Functions#

Version Functions#

The version of the package can be returned as a single string or a dict.

When a string, it comes from the package __version__. When a dict, it also has __version__, as well as versions of other depdency packages.

dls_bxflow_epsic.version.version()[source]#

Version of the dls_bxflow_epsic package as a string.

Return type:

str

dls_bxflow_epsic.version.meta(given_meta=None)[source]#

Returns version information from the dls_bxflow_epsic package and its dependencies as a dict. Adds version information to a given meta dict if it was provided.

Parameters:

given_meta (dict | None) –

Return type:

dict

Utility Functions#

dls_bxflow_epsic.utilities.is_done_filename_2_data_label(is_done_filename)[source]#

Given a full “is_done” filename path, derive a data label from it.

Rules:
  1. the data_filename must have /Merlin/ somwhere in the path.

  2. the final directory in the path is ignored.

  3. whatever is between /Merlin/ and that final directory, is the data_label.

  4. this works for is_done files whose name differ from their mib files by suffix only.

Parameters:

is_done_filename (str) –

Return type:

str

dls_bxflow_epsic.utilities.mib_filename_2_data_label(mib_filename)[source]#

Given a full mib filename path, derive a data label from it.

Rules:
  1. the data_filename must have /Merlin/ somwhere in the path.

  2. the final directory in the path is ignored.

  3. whatever is between /Merlin/ and that final directory, is the data_label.

  4. this works for is_done files whose name differ from their mib files by suffix only.

Parameters:

mib_filename (str) –

Return type:

str

dls_bxflow_epsic.utilities.data_label_2_mib_filename(data_label)[source]#

Given a data label, compose a full filename path to the mib file.

Parameters:

data_label (str) –

Return type:

str

dls_bxflow_epsic.utilities.data_label_2_processing(data_label, nickname=None)[source]#

Return processing directory where data_label stuff is saved. This area is outside any task’s specific instance directory. That is, all tasks of all jobs ever run share reading and writing into this directory.

If nickname is provided, it is used to customize the actual filename produced for the data label.

Parameters:
Return type:

str

dls_bxflow_epsic.utilities.configuration_2_byv()[source]#

Returns the beamline, year and visit indicated by the configuration.

Returns:

beamline, year, visit

Return type:

Tuple[str, str, str]

dls_bxflow_epsic.utilities.data_filename_2_byv(data_filename)[source]#

Returns the beamline, year and visit indicated by the filename.

Returns:

beamline, year, visit

Return type:

Tuple[str, str, str]

Parameters:

data_filename (str) –

dls_bxflow_epsic.utilities.mib_filename_2_filestore_directory(mib_filename)[source]#

From the mib_filename, derive the associated directory name where execution results can be written.

Parameters:

mib_filename (str) – full path to mib filename

Returns:

directory in the visit’s procecssing area, with data label as leaf

Return type:

str

dls_bxflow_epsic.utilities.data_label_2_filestore_directory(data_label)[source]#

From the data_label, derive the associated directory name where execution results can be written.

Parameters:

data_label (str) – data_label for this dataset

Returns:

directory in the visit’s procecssing area, with data label as leaf

Return type:

str