Mantid Workbench - Tutorial for ISIS SANS data reduction
02 Jun 2020
Yes
-  

 

 

 

No
 

SANS Group | SANS Instruments | SANS Team | ​Science | Sample Environment | Data Analysis

Install Mantid Workbench

Download from: https://download.mantidproject.org/

O. Arnold, et al., Mantid—Data analysis and visualization package for neutron scattering and μSR experiments, Nuclear Instruments and Methods in Physics Research Section A, 764 (2014) 156-166, http://dx.doi.org/10.1016/j.nima.2014.07.029


This tutorial will help you to:

Part I
- Organize a Batch File
- Setup Mantid
- Reduce Data (file types)
Part II

- Manage plots

Part III
- Add runs
- Use event mode
- Slice wavelength ranges
Part IV
- Merge small and high angle
- Use Algorithms
- Run a Python Script


Part I:

Organize your data in a Batch File

During the experiment, open the Journal Viewer in order to see the run numbers of your samples, as you see in the picture below. In “Display", select the Instrument, the number of the cycle and use the refresh button to update the screen; use Filters to narrow the list of files; the tab "View" allows you to select what columns appear in the list; then save the document in “File>Save as PDF" for you to keep a copy of this list together with your data.

 

If you are using IDAaaS, the cloud-based data analysis platform, then you have access to the Journal Viewer trhough the tab "Software", like in the example below:



Remember that you wrote the names of your samples in your script file. These names, followed by the extension TRANS (for transmission measurement), SANS or SANS/TRANS (when SANS and TRANS are measured at the same time), will appear on the Journal Viewer accompanied by a number after each run. For example: the sample name “A2" will appear as “108118 A2_TRANS" as in the picture above.



Using the template attached here, organize your data in a ".csv" file as in the picture above. Collect the numbers of your files from JournalViewer and write them down as highlighted here: in RED, the sample files; in BLUE the reference or background sample (“Can"); in GREEN, the Direct Beam and in YELLOW the name you wish the file will receive after data reduction. You will shortly upload this “.csv" file into MANTID.

Open Mantid Workbench

Then click on "Interfaces > SANS > ISIS SANS" to open the Graphical User Interface (GUI):


In the GUI, click on Manage Directories > Browse To Directory to set the folders where your raw data, user files, masks and associated files are stored. Here we are showing an example for reducing LOQ data at ISIS. The paths for directories will be different on your own computer.




Also set “Default Save Directory > Browse To Directory", to set the folder where the reduced data will be saved.





Click on "Load User File" to load the Mantid configuration file built specifically for the day of your experiment (talk to your local contact). Depending on the complexity of the experiment, there may be more than one variant of the User File (different binning schemes, different sector averages, etc.).


 

Now click on Load Batch File, to load the “.csv" file where you listed your files to be reduced. This populates the table in the SANS Reduction GUI. Note that in the table you can specify a different User File for individual rows, or override the sample thickness stored in the Sample Scatter run (which will normally have been set in your measurement script) or, if you check the "Sample Geometry" box, even override the Sample Shape, Height or Width.


You can also build the Batch File using the Export button of the GUI. It can be useful when you want to change one detail when you are in the GUI and then save your modifications as a new batch file.



On the right bottom corner, choose Save Options as in the picture above (learn more about these file types here). Then click on Process All. You can also select few lines and use Process Selected, in case you only want to process a few samples from the table. Each time you process a row, you overwrite existing output files with the same name. A long list of files can take several minutes to process. The lines will become GREEN if the process was successful, or BLUE if you have a typo, for example (in this case, fix the typo, select the row(s) and process again). The thickness of the sample (in this picture, 2.0) will appear exactly as you declared on your script file.



The green bar on the bottom indicates the progress of the process. You can now minimize the GUI window and continue to monitor the process through the main window of MANTID WORKBENCH. In this window you can also monitor the messages during the reduction process, manage plots, use pre-existing algorithms and run Python scripts.


More technical information regarding the use of MANTID for ISIS SANS Data Reduction can be found at

https://www.mantidproject.org/ISIS_SANS​



Contact: Cavalcanti, Leide (STFC,RAL,ISIS)