Spectroscopy tasks#

How to use

These tasks come from est ewoksxas. It can be installed with

pip install est ewoksxas

ℹ️ These tasks are used at the following ESRF beamlines: BM08, BM23, ID24

IgnoreOutput#

Simple Ignore task when an input is provided but no output. Used in the case of pure display widget.

.. note::

Each OW should define it own task to ensure a safe conversion to ewoks.
Identifier:
est.core.process.ignoreprocess.IgnoreOutput
Task type:
class
Inputs:
xas_obj*

BlankTask#

Simple black task which will copy received xas_obj from inputs to outputs.

.. note::

Each OW should define it own task to ensure a safe conversion to ewoks.
Identifier:
est.core.process.ignoreprocess.BlankTask
Task type:
class
Inputs:
xas_obj*
Outputs:
xas_obj

IgnoreSavingPoint#

Identifier:
est.core.process.ignoreprocess.IgnoreSavingPoint
Task type:
class
Inputs:
xas_obj*
Outputs:
xas_obj

IgnoreE0Calculation#

Identifier:
est.core.process.ignoreprocess.IgnoreE0Calculation
Task type:
class
Inputs:
xas_obj*
Outputs:
xas_obj

PlotSpectrumData#

Identifier:
est.core.process.plotspectrumdata.PlotSpectrumData
Task type:
class
Inputs:
xas_obj*
plot_names
Outputs:
plot_data

SplitBlissScan#

Split a Bliss scan in subscans as determined by a channel which is monotonically increasing or descreasing in each subscan or determined by subscan size.

param input_names:

  • filename: HDF5 file name containing the Bliss scan.

  • scan_number: The Bliss scan number.

  • monotonic_channel: HDF5 path relative to the scan group.

  • out_filename: HDF5 file name to save subscans as a result of splitting the Bliss scan.

param optional_input_names:

  • subscan_size: Fix length subscan size.

  • trim_n_points: Trim N points from the start and end of each subscan.

  • wait_finished: Wait for the Bliss scan to be complete in HDF5.

  • retry_timeout: Timeout of waiting for the Bliss scan to be complete in HDF5.

  • retry_period: Check period of waiting for the Bliss scan to be complete in HDF5.

  • counter_group: Group of counters to check whether a subscan is fully complete.

param output_names:

  • out_urls: HDF5 URL’s of the subscans as a result of splitting the Bliss scan.

Identifier:
est.core.process.split.SplitBlissScan
Task type:
class
Inputs:
filename*
monotonic_channel*
out_filename*
scan_number*
counter_group
retry_period
retry_timeout
subscan_size
trim_n_points
wait_finished
Outputs:
out_urls

AutoBK#

Task to calculate k-space for X-ray absorption spectra using Larch.

Identifier:
ewoksxas.tasks.autobk.AutoBK
Task type:
class
Inputs:
Data* : Orange.data.table.Table
parameters : dict
Outputs:
Data : Orange.data.table.Table
Groups : list[larch.symboltable.Group]

CombineRows#

Apply a mathematical equation to groups of rows.

Identifier:
ewoksxas.tasks.combine_rows.CombineRows
Task type:
class
Inputs:
Data* : Orange.data.table.Table
grouping_column : str | None= None
equation_terms_column : str | None= None
equation : str=
mode : str= insert
Outputs:
Data : Orange.data.table.Table

LinearCombinationAnalysis#

Task to do linear combination analysis on X-ray absorption spectra.

Identifier:
ewoksxas.tasks.lca.LinearCombinationAnalysis
Task type:
class
Inputs:
Sample_Data* : Orange.data.table.Table
Component_Data* : Orange.data.table.Table
parameters : dict
Outputs:
Transformed_Data : Orange.data.table.Table
Data : Orange.data.table.Table
Components : Orange.data.table.Table

Normalize#

Task to normalize X-ray absorption spectra using Larch.

Identifier:
ewoksxas.tasks.normalize.Normalize
Task type:
class
Inputs:
Data* : Orange.data.table.Table
parameters : dict
Outputs:
Data : Orange.data.table.Table
Groups : list[larch.symboltable.Group]

PeakFitting#

Task to fit one or several peaks of a single shape to each spectrum.

Wraps :class:ewoksxas.fit.peak_fit.PeakModel: every spectrum in the input table is fitted with the configured peak shape and baseline (read from parameters via PeakModel.from_dict), and the fitted model curves are returned with the per-peak descriptors (center, height, area, FWHM and its Gaussian/Lorentzian contributions and the mixing fraction) as metadata.

Each per-peak descriptor base becomes the columns base_0, base_1, … up to the largest peak count fitted across the run, NaN-padded for spectra with fewer peaks; the bare base column aliases the first peak so single-peak consumers keep working. The per-fit quality (r2, rmse) and the integer n_peaks are added once per spectrum. The input table’s metadata (e.g. Scan Name and any acquisition metas) is carried through to the output, with these fit descriptors taking precedence on name collisions.

Identifier:
ewoksxas.tasks.peak_fit.PeakFitting
Task type:
class
Inputs:
Data* : Orange.data.table.Table
parameters : dict
Outputs:
Data : Orange.data.table.Table

ReadScans#

Task to read scan data and metadata from files.

Identifier:
ewoksxas.tasks.read_scans.ReadScans
Task type:
class
Inputs:
Data* : Orange.data.table.Table
x* : str
counters* : list[ewoksxas.tasks.read_scans.CounterInfo]
metadata* : list[ewoksxas.tasks.read_scans.MetadataInfo]
x_interp_grid : list[float] | None= None
Outputs:
Data : Orange.data.table.Table

Xftf#

Task to calculate k-space for X-ray absorption spectra using Larch.

Identifier:
ewoksxas.tasks.xftf.Xftf
Task type:
class
Inputs:
Data* : Orange.data.table.Table
parameters : dict
Outputs:
Data : Orange.data.table.Table
Groups : list[larch.symboltable.Group]