diff --git a/Testing/LiveData/LiveDataTests.html b/Testing/LiveData/LiveDataTests.html index a6efcc9f..40de54a8 100644 --- a/Testing/LiveData/LiveDataTests.html +++ b/Testing/LiveData/LiveDataTests.html @@ -105,35 +105,36 @@
A video example of using multiple live streams and full direct elastic data reduction can be seen here.
+A video example of using multiple live streams and full direct elastic data reduction can be seen here.
The rest of this document describes some examples you can run yourself using a fake instrument which simulates the arrival of new data.
For all of these tests you will need to change your Facility to TEST_LIVE
, as described below.
You can use MantidWorkbench.
Time required 20 - 30 minutes
In MantidWorkbench:
Open the File
menu and select Settings
You can follow the same approach to set your facility back afterwards.
Run the FakeISISEventDAE
Algorithm from the Algorithms toolbox
These settings will create an instrument with 100 spectra, transmitting 2000 events every 20 milliseconds in 1 period. The data is between 10,000 and 20,000 microseconds TOF:
+Run the FakeISISEventDAE
algorithm from the Algorithms toolbox
The following settings will create an instrument with 100 spectra, transmitting 2000 events every 20 milliseconds in 1 period. The data is between 10,000 and 20,000 microseconds TOF:
Running this algorithm will produce “FakeISISEventDAE started
” in the Messages panel, but will not make any other data appear yet.
Run the FakeISISHistoDAE
Algorithm from the Algorithms toolbox
These settings will create an instrument with 100 spectra, with 100 bins in 1 period:
+The following settings will create an instrument with 100 spectra, with 100 bins in 1 period:
NPeriods = 1
NSpectra = 100
To stop the fake instrument, open the Algorithm Details window, by clicking on the Details
button at the bottom of the Algorithms Toolbox. Then click Cancel
next to FakeISISHistoDAE
.
Running this algorithm will produce “FakeISISHistoDAE started
” in the Messages panel, but will not make any other data appear yet.
This approach reads from an SNS pre-nexus file or an event-nexus file to recreate realistic event data, however It is a little more fiddly to setup.
Find the file Mantid.user.properties
. Its location will be:
Mac or linux: ~/.mantid
(i.e. in a .mantid
directory under your home directory)
To use a pre-nexus file, use the REF_L_32035_neutron_event.dat
file (located in the TrainingCourseData
folder), open Mantid.user.properties
in your favorite text editor and add the following lines:
To use a pre-nexus file, use the REF_L_32035_neutron_event.dat
file (located in the TrainingCourseData
folder), open the Mantid.user.properties
file in your favorite text editor and add the following lines:
fileeventdatalistener.filename=REF_L_32035_neutron_event.dat
fileeventdatalistener.chunks=300
fileeventdatalistener.filename=EQSANS_6071_event.nxs
Chunking for files can be determined by using the DetermineChunking algorithm.
+For MantidWorkbench to find these files, they must be in a directory listed under “Data Search Directories” in the “Manage User Directories” menu. Chunking for files can be determined by using the DetermineChunking algorithm.
Start MantidWorkbench
Use the instrument ADARA_FileReader
in the TEST_LIVE
facility in the Settings dialog (MantidWorkbench). There is no need to stop this fake instrument.
Ensure that FakeISISHistoDAE
and FakeISISEventDAE
are running in the background to complete this example
To open the StartLiveData
interface you can either
click the drop down Load
button in the Workspaces toolbox and select Live Data
Click the drop down Load
button in the Workspaces toolbox and select Live Data
Run the StartLiveData
algorithm from the Algorithms toolbox
Setup: ISIS Event
+Enter the following settings in the StartLiveData interface:
+Instrument: ISIS_Event
Start Time: now
Update Every: 1 second
Processing: No Processing
Accumulation Method: Replace
Post Processing: No Processing
OutputWorkspace: live
Click “Run”.
+You should see successive messages in MantidWorkbench of the form Loading live data chunk x at xx:xx:xx
.
Setup : ISIS Histogram
+Setup : ISIS Histogram
Note that for Histogram data the accumulationMethod
needs to be set to Replace
, otherwise you will get a warning.
Enter the following settings in the StartLiveData interface:
Post Processing: No Processing
OutputWorkspace: live
Click “Run”.
+You should see successive messages in MantidWorkbench of the form Loading live data chunk x at xx:xx:xx
.
Setup : ADARA Fake Event
+Setup : ADARA Fake Event
Enter the following settings in the StartLiveData interface:
Instrument: ADARA_FakeEvent
Within the Processing step tab select the Rebin
algorthm
In the algorithm properties set Params
to 40e3,1000,60e3
PreserveEvents
should be unticked
PreserveEvents: unticked
Accumulation Method: Add
OutputWorkspace: live
Click “Run”.
+You should see successive messages in MantidWorkbench of the form Loading live data chunk x at xx:xx:xx
.
Double-click on the live
workspace, then select Plot All
. You should see a histogram with two lines automatically updating as “new” data appears.
This uses rebin to select a region of time of flight, and then after +
This uses Rebin to select a region of time of flight, and then after the data is accumulated it uses SumSpectra to sum all of the data into a single spectrum. When using post processing you have to give the accumulation workspace a name.
-Setup : ADARA Fake Event
+Setup : ADARA Fake Event
Enter the following settings in the StartLiveData interface:
Instrument: ADARA_FakeEvent
Within the Processing step tab select the Rebin
algorthm
In the algorthim properties set Params
to 40e3,500,60e3
PreserveEvents
should be unticked
PreserveEvents: Not Ticked
Accumulation Method: Add
Post Processing: Algorithm
Within the Post Processing step tab select the SumSpectra
algorthm
The options can be left as their defaults
AccumulationWorkspace: accumulation
OutputWorkspace: live
Click “Run”.
+You should see successive messages in MantidWorkbench of the form Loading live data chunk x at xx:xx:xx
.
Double-click on the live
workspace. You should see a histogram with one line automatically updating as “new” data appears.
+Double-click on the accumulation
workspace, then select Plot All
. You should see a histogram with two lines automatically updating as “new” data appears.
A live data session will run until it is cancelled or Mantid is closed. To cancel a session:
To stop the live data session, open the Algorithm Details
window, by clicking on the button at the bottom of the Algorithms Toolbox