\(\renewcommand\AA{\unicode{x212B}}\)
Table of Contents
Name | Direction | Type | Default | Description |
---|---|---|---|---|
Filename | Input | string | Mandatory | File path of the data file to load. Allowed extensions: [‘.nxs’] |
OutputWorkspace | Output | WorkspaceGroup | Mandatory | The output workspace. |
PositionCalibration | Input | string | None | Select the type of pixel position calibration. If None, the pixel positions are read from IDF file. If Nexus, the positions are read from Nexus file. If YIGFile, then the calibration twotheta data is loaded from a user-defined calibration file. Allowed values: [‘None’, ‘Nexus’, ‘YIGFile’] |
YIGFilename | Input | string | File path of the YIG calibration data file to load. Allowed extensions: [‘.xml’] | |
ConvertToScatteringAngle | Input | boolean | False | Convert the bin edges to scattering angle. |
TransposeMonochromatic | Input | boolean | False | Transpose the 2D workspace with monochromatic data |
TOFUnits | Input | string | UncalibratedTime | The choice of X-axis units for Time-Of-Flight data. Allowed values: [‘UncalibratedTime’, ‘TimeChannels’] |
This is the loader for the raw .nxs files produced by the polarized diffractometers and spectrometers at ILL. Currently it supports only the D7 instrument.
For D7 1-dimensional detector, it supports 3 types of pixel alignment relative to detector banks:
All alignment methods allow for independent movement of banks.
The 2theta value of each bank is read from the file, and it refers to the middle point of the bank. The sum of pixel’s and bank 2theta determine their final position in 3D space.
Note
To run these usage examples please first download the usage data, and add these to your path. In Mantid this is done using Manage User Directories.
Example - LoadILLPolarizedDiffraction - D7 spectroscopy
wsGroup = LoadILLPolarizedDiffraction(Filename='ILL/D7/395850.nxs')
print('The output has {0} entries'.format(wsGroup.getNumberOfEntries()))
ws1 = wsGroup.getItem(0)
print('Each entry has {0} bins (Time of Flight mode) and {1} spectra'.format(ws1.blocksize(), ws1.getNumberHistograms()))
Output:
The output has 2 entries
Each entry has 512 bins (Time of Flight mode) and 134 spectra
Example - LoadILLPolarizedDiffraction - D7 NeXuS alignment monochromatic
wsGroup = LoadILLPolarizedDiffraction(Filename='ILL/D7/401800.nxs')
print('The output has {0} entries'.format(wsGroup.getNumberOfEntries()))
ws1 = wsGroup.getItem(0)
print('Each entry has {0} bins (monochromatic mode) and {1} spectra'.format(ws1.blocksize(), ws1.getNumberHistograms()))
Output:
The output has 6 entries
Each entry has 1 bins (monochromatic mode) and 134 spectra
Categories: AlgorithmIndex | DataHandling\Nexus | ILL\Diffraction
C++ header: LoadILLPolarizedDiffraction.h (last modified: 2021-03-31)
C++ source: LoadILLPolarizedDiffraction.cpp (last modified: 2021-03-31)