ess.bifrost.detector.get_calibrated_detector_bifrost#

ess.bifrost.detector.get_calibrated_detector_bifrost(detector, *, transform, offset)[source]#

Extract the data array corresponding to a detector’s signal field.

The returned data array includes coords and masks pertaining directly to the signal values array, but not additional information about the detector. The data array is reshaped to the logical detector shape.

This function is specific to BIFROST and differs from the generic ess.reduce.nexus.workflow.get_calibrated_detector() in that it does not fold the detectors into logical dimensions because the files already contain the detectors in the correct shape.

Parameters:
  • detector (NeXusComponent[NXdetector, TypeVar(RunType, ess.reduce.nexus.types.SampleRun (int), ess.reduce.nexus.types.VanadiumRun (int))]) – Loaded NeXus detector.

  • transform (NeXusTransformation[NXdetector, TypeVar(RunType, ess.reduce.nexus.types.SampleRun (int), ess.reduce.nexus.types.VanadiumRun (int))]) – Transformation that determines the detector position.

  • offset (DetectorPositionOffset[TypeVar(RunType, ess.reduce.nexus.types.SampleRun (int), ess.reduce.nexus.types.VanadiumRun (int))]) – Offset to add to the detector position.

Returns:

CalibratedDetector[TypeVar(RunType, ess.reduce.nexus.types.SampleRun (int), ess.reduce.nexus.types.VanadiumRun (int))] – Detector data.