SaveMask v1

../_images/SaveMask-v1_dlg.png

SaveMask dialog.

Summary

Save a MaskWorkspace/SpecialWorkspace2D to an XML file.

Properties

Name Direction Type Default Description
InputWorkspace Input MatrixWorkspace Mandatory Workspace to output masking to XML file
OutputFile Input string Mandatory File to save the detectors mask in XML format. Allowed extensions: [‘.xml’]

Description

This algorithm is used to save the masking from a workspace to an XML file. This algorithm has previously been renamed from SaveDetectorMasks.

2 Types of Mask Workspace

There are two types of mask workspace that can serve as input.

1. MaskWorkspace

In this case, SaveMask v1 will read Y values to determine which detectors are masked;

2. A non-MaskWorkspace MatrixWorkspace containing Instrument

In this case, SaveMask v1 will scan through all detectors to determine which are masked.

Definition of Mask

If a pixel is masked, it means that the data from this pixel won’t be used. In the masking workspace (i.e., SpecialWorkspace2D), the corresponding value is 1.

If a pixel is NOT masked, it means that the data from this pixel will be used. `` In the masking workspace (i.e., SpecialWorkspace2D), the corresponding value is 0.

XML File Format

Example 1:

<?xml version="1.0" encoding="UTF-8" ?>
<detector-masking>
  <group>
    <detids>3,34-44,47</detids>
    <component>bank123</component>
    <component>bank124</component>
  </group>
</detector-masking>

Categories: AlgorithmIndex | DataHandling\Masking | Transforms\Masking

Source

C++ source: SaveMask.cpp (last modified: 2019-06-05)

C++ header: SaveMask.h (last modified: 2018-10-05)