Table of Contents
Name | Direction | Type | Default | Description |
---|---|---|---|---|
ReductionType | Input | string | ReduceSample | Choose whether to treat a sample or a water run to calculate sensitivity. Allowed values: [‘ReduceSample’, ‘ReduceWater’] |
OutputWorkspace | Output | WorkspaceGroup | Mandatory | The output workspace group containing reduced data. |
SampleRuns | Input | list of str lists | Sample run(s). Allowed values: [‘nxs’] | |
AbsorberRuns | Input | list of str lists | Absorber (Cd/B4C) run(s). Allowed values: [‘nxs’] | |
BeamRuns | Input | list of str lists | Empty beam run(s). Allowed values: [‘nxs’] | |
FluxRuns | Input | list of str lists | Empty beam run(s) for flux calculation only; if left blank flux will be calculated from BeamRuns. Allowed values: [‘nxs’] | |
ContainerRuns | Input | list of str lists | Empty container run(s). Allowed values: [‘nxs’] | |
SampleTransmissionRuns | Input | list of str lists | Sample transmission run(s). Allowed values: [‘nxs’] | |
ContainerTransmissionRuns | Input | list of str lists | Container transmission run(s). Allowed values: [‘nxs’] | |
TransmissionBeamRuns | Input | list of str lists | Empty beam run(s) for transmission. Allowed values: [‘nxs’] | |
TransmissionAbsorberRuns | Input | list of str lists | Absorber (Cd/B4C) run(s) for transmission. Allowed values: [‘nxs’] | |
SensitivityMaps | Input | list of str lists | File(s) containing the map of relative detector efficiencies. Allowed values: [‘nxs’] | |
DefaultMaskFile | Input | string | File containing the default mask to be applied to all the detector configurations. Allowed values: [‘nxs’] | |
MaskFiles | Input | list of str lists | File(s) containing the beam stop and other detector mask. Allowed values: [‘nxs’] | |
ReferenceFiles | Input | list of str lists | File(s) containing the corrected water data for absolute normalisation. Allowed values: [‘nxs’] | |
SensitivityOutputWorkspace | Output | MatrixWorkspace | The output sensitivity map workspace. | |
NormaliseBy | Input | string | Timer | Choose the normalisation type. Allowed values: [‘None’, ‘Timer’, ‘Monitor’] |
SampleThickness | Input | number | 0.1 | Sample thickness [cm] |
BeamRadius | Input | number | 0.05 | Beam raduis [m]; used for beam center finding, transmission and flux calculations. |
WaterCrossSection | Input | number | 1 | Provide water cross-section; used only if the absolute scale is done by dividing to water. |
OutputType | Input | string | I(Q) | Choose the output type. Allowed values: [‘I(Q)’, ‘I(Qx,Qy)’, ‘I(Phi,Q)’] |
CalculateResolution | Input | string | MildnerCarpenter | Choose to calculate the Q resolution. Allowed values: [‘MildnerCarpenter’, ‘None’] |
DefaultQBinning | Input | string | PixelSizeBased | Choose how to calculate the default Q binning. Allowed values: [‘PixelSizeBased’, ‘ResolutionBased’] |
BinningFactor | Input | number | 1 | Specify a multiplicative factor for default Q binning (pixel or resolution based). |
OutputBinning | Input | dbl list | The manual Q binning of the output | |
NPixelDivision | Input | number | 1 | Number of subpixels to split the pixel (NxN) |
NumberOfWedges | Input | number | 0 | Number of wedges to integrate separately. |
WedgeWorkspace | Output | WorkspaceGroup | WorkspaceGroup containing I(Q) for each azimuthal wedge. | |
WedgeAngle | Input | number | 30 | Wedge opening angle [degrees]. |
WedgeOffset | Input | number | 0 | Wedge offset angle from x+ axis. |
AsymmetricWedges | Input | boolean | False | Whether to have asymmetric wedges. |
MaxQxy | Input | number | 0 | Maximum of absolute Qx and Qy. |
DeltaQ | Input | number | 0 | The dimension of a Qx-Qy cell. |
IQxQyLogBinning | Input | boolean | False | I(Qx, Qy) log binning when binning is not specified. |
This algorithms performs complete treatment of SANS data recorded with the ILL instruments D11, D22 and D33. This high level algorithm steers the reduction and performs the full set of corrections for a given sample run; measured with one or more detector distances. It has two operation modes: ReduceSample (default) and ReduceWater as follows:
This mode is used to correct the sample measurement and convert it to Q-space, producing by default the azimuthal average curve .
This mode should be used to process water reference measurement in order to derive the relative inter-pixel sensitivity map of the detector. This mode will produce two outputs; the regular output will contain fully corrected water run, and there will be an additional output containing the sensitivity map itself. The sensitivity map can be saved out to a file and used for sample reductions.
This algorithm does not clean-up the intermediate workspaces after execution. This is done intentionally for performance reasons. For example, once the transmission of a sample is calculated, it will be reused for further iterations of processing of the same sample at different detector distances. As other example, once the container is processed at a certain distance, it will be reused for all the subsequent samples measured at the same distance, if the container run is the same. The same caching is done for absorber, empty beam, container, sensitivity and mask workspaces. The caching relies on Analysis Data Service (ADS) through naming convention by appending the relevant process name to the run number. When multiple runs are summed, the run number of the first run is attributed to the summed workspace name.
Note
To run these usage examples please first download the usage data, and add these to your path. In MantidPlot this is done using Manage User Directories.
Example - full treatment of 3 samples at 3 different distances
beams = '2866,2867+2868,2878'
containers = '2888+2971,2884+2960,2880+2949'
container_tr = '2870+2954'
beam_tr = '2867+2868'
samples = ['2889,2885,2881',
'2887,2883,2879',
'3187,3177,3167']
sample_tr = ['2871', '2869', '3172']
thick = [0.1, 0.2, 0.2]
# reduce samples
for i in range(len(samples)):
SANSILLAutoProcess(
SampleRuns=samples[i],
BeamRuns=beams,
ContainerRuns=containers,
MaskFiles='mask1.nxs,mask2.nxs,mask3.nxs',
SensitivityMaps='sens-lamp.nxs',
SampleTransmissionRuns=sample_tr[i],
ContainerTransmissionRuns=container_tr,
TransmissionBeamRuns=beam_tr,
SampleThickness=thick[i],
OutputWorkspace='iq_s' + str(i + 1)
)
print('Distance 1 Q-range:{0:4f}-{1:4f} AA'.format(mtd['iq_s1_1'].readX(0)[0], mtd['iq_s1_1'].readX(0)[-1]))
print('Distance 2 Q-range:{0:4f}-{1:4f} AA'.format(mtd['iq_s1_2'].readX(0)[0], mtd['iq_s1_2'].readX(0)[-1]))
print('Distance 3 Q-range:{0:4f}-{1:4f} AA'.format(mtd['iq_s1_3'].readX(0)[0], mtd['iq_s1_3'].readX(0)[-1]))
Output:
Distance 1 Q-range:0.001386-0.020065 AA
Distance 2 Q-range:0.007000-0.091962 AA
Distance 3 Q-range:0.032726-0.343775 AA
Categories: AlgorithmIndex | ILL\SANS | ILL\Auto
Python: SANSILLAutoProcess.py (last modified: 2019-09-12)