Table of Contents
Name | Direction | Type | Default | Description |
---|---|---|---|---|
Filename | Input | string | Mandatory | File path of the Data file to load. Allowed extensions: [‘.nxs’] |
FilenameVanadium | Input | string | File path of the Vanadium file to load (Optional). Allowed extensions: [‘.nxs’] | |
WorkspaceVanadium | Input | MatrixWorkspace | Vanadium Workspace file to load (Optional) | |
OutputWorkspace | Output | MatrixWorkspace | Mandatory | The name to use for the output workspace |
Loads an ILL TOF NeXus file into a Workspace2D with the given name.
This loader calculates the elastic peak position (EPP) on the fly. In cases where the dispersion peak might be higher than the EPP, it is good practice to load a Vanadium file.
The property FilenameVanadium is optional. If it is present the EPP will be loaded from the Vanadium data.
To date this algorithm only supports: IN4, IN5 and IN6
Example - Load a regular histogram Nexus file: (see LoadILLTOF v1 for more options)
# Regular data file.
dataRegular = 'ILLIN6_151460.nxs'
# Load ILL dataset
ws = Load(dataRegular)
print "This workspace has", ws.getNumDims(), "dimensions and has", ws.getNumberHistograms(), "histograms."
Output:
This workspace has 2 dimensions and has 340 histograms.
Example - Load a histogram Nexus file where the dispersion peak is higher than the elastic peak. An auxiliary vanadium file is needed to locate the elastic peak.: (see LoadILLTOF v1 for more options)
# Data file where the dispersion peak is higher than the elastic peak.
dataDispersionPeak = 'ILLIN5_Sample_096003.nxs'
# Vanadium file collected in the same conditions as the dispersion peak dataset.
vanaDispersionPeak = 'ILLIN5_Vana_095893.nxs'
# Load ILL dispersion peak dataset and a vanadium dataset
ws = Load(dataDispersionPeak, FilenameVanadium=vanaDispersionPeak)
print "This workspace has", ws.getNumDims(), "dimensions and has", ws.getNumberHistograms(), "histograms."
Output:
This workspace has 2 dimensions and has 98305 histograms.
Example - Same example as above, but the vanadium file is loaded in advance. The dataset for the dispersion peak is loaded after, using the auxiliary vanadium workspace.: (see LoadILLTOF v1 for more options)
# Data file where the dispersion peak is higher than the elastic peak.
dataDispersionPeak = 'ILLIN5_Sample_096003.nxs'
# Vanadium file collected in the same conditions as the dispersion peak dataset.
vanaDispersionPeak = 'ILLIN5_Vana_095893.nxs'
# Load the Vanadium
wsVana = Load(dataDispersionPeak)
# Load ILL dispersion peak dataset and a vanadium dataset
wsData = Load(dataDispersionPeak, WorkspaceVanadium=wsVana)
print "The Vanadium workspace has", wsVana.getNumDims(), "dimensions and has", wsVana.getNumberHistograms(), "histograms."
print "The Data workspace has", wsData.getNumDims(), "dimensions and has", wsData.getNumberHistograms(), "histograms."
Output:
The Vanadium workspace has 2 dimensions and has 98305 histograms. The Data workspace has 2 dimensions and has 98305 histograms.
Categories: Algorithms | DataHandling\Nexus