Skip to content

data_retrieval_http

Retrieval and handling of data from the http/REST interface.

This module contains Data Retrieval classes that deal with the HTTP/REST interface used by detectors manufactured by the company Dectris.

EigerHttpDataRetrieval

Bases: OmDataRetrievalProtocol

See documentation of the __init__ function.

__init__(*, monitor_parameters, source)

Data Retrieval from Eiger's HTTP/REST interface.

This class implements OM's Data Retrieval Layer for the HTTPS/REST interface of an Eiger detector.

This class implements the interface described by its base Protocol class. Please see the documentation of that class for additional information about the interface.

  • This class considers an individual data event as equivalent to the content of a tif file retrieved from the Eiger's HTTP/REST interface, which stores data related to a single detector frame.

  • A string with the format: {SeriesID_FrameID}, where SeriesID and FrameID are two values generated for each event by the HTTP/REST interface, is used as event identifier.

  • Since Eiger's HTTP/REST monitor interface does not provide any detector distance or beam energy information, their values are retrieved from OM's configuration parameters (specifically, the fallback_detector_distance_in_mm and fallback_beam_energy_in_eV entries in the data_retrieval_layer parameter group).

  • The source string for this Data Retrieval class is the base URL of the 'monitor' subsystem of the Eiger's HTTP/REST interface: http://<address_of_dcu>/monitor/api/<version>.

Parameters:

Name Type Description Default
monitor_parameters MonitorParameters

An object storing OM's configuration parameters.

required
source str

A string describing the data event source.

required

get_data_event_handler()

Retrieves the Data Event Handler used by the Data Retrieval class.

Please see the documentation of the base Protocol class for additional information about this method.

Returns:

Type Description
OmDataEventHandlerProtocol

The Data Event Handler used by the Data Retrieval class.