Matthew Whyndham
August 16, 2001
Procedures for generating and checking GSETS.............................................................................
Purpose of this document...........................................................................................................
Background...............................................................................................................................
The procedure in brief................................................................................................................
Deciding that a GSET is required................................................................................................
Examination of existing GSETs...................................................................................................
Producing raw data....................................................................................................................
Choosing the high voltage level...................................................................................................
View the raw data.....................................................................................................................
Adjust gains and other LUT parameters......................................................................................
Repeat for all detectors..............................................................................................................
Definition of GSET in database...................................................................................................
Further information........................................................................................................................
Raw files...................................................................................................................................
Audience: Researchers in the SOHO-CDS project or scientists working with data who wish to understand how the Grazing Incidence Spectrometer (GIS) is configured for each observation.
The configuration information for the SOHO-CDS Grazing Incidence Spectrometer (GIS) is stored in a structure known as a “GSET” (GIS setup).
After reading this document, a suitably equipped person should have sufficient knowledge to allow them to specify the ideal GIS configuration for observations based on a set of raw files appropriate to the proposed observational conditions.
Additionally, a data analyst will be able to assess the quality of an existing GSET by examination of the raw data. This may assist in the understanding of features in the science data (spectra).
It is assumed that the reader will have been introduced to the workings of the CDS and the GIS, and that the data analysis software distribution, including the raw data files, is available[1] to them.
1. Determine that a new GSET is required - optionally examine existing GSET
2. Produce raw data
3. Choose the High voltage
4. Choose the Gains and Lookup table parameters
5. Repeat steps 1-4 for all detectors
6. Prepare the GSET definition in the database
A new GSET is required if any of the following statements are true:
· a slit/Zone/HV combination has not yet had a GSET produced for it, or
· The detector has changed to an extent that the existing GSET is invalid.
· An analyst may feel that the spectra obtained with a current GSET show undesirable features (ghosting being the classic case) and that a new GSET would not. In this case the new GSET should be generated using these procedures and the observations repeated with the new GSET.
· Table of key GSETs: http://www.mssl.ucl.ac.uk/~mwt/soho/keygsets/keygsets.htm
· Tree-Routines which apply to GSETs :
IDL> tftd,'gset
Thoughts for the day produced by TFTD q.v.
ADD_GSET() - Adds an entry to the GIS setup
database.
GET_GSET - Extracts a GIS raw data file entry
from the database
LIST_GSET - List GIS setup
MOD_GSET() - Modifies a GIS setup definition in
the database
ex_gset
I don’t know why MK_GSET doesn’t appear in this list!
LIST_GSET and GET_GSET can be used by general users to retrieve information from the database.
· The tool XV_RAW is able to retrieve and display the raw file when given the GSET id and detector number.
This part of the procedure is normally carried out by the CDS operators at the EOF[2]. The operator should be asked to prepare a set of GIS raw files according to these procedures.
The slit number, solar Zone and a range of HV’s will need to be specified. The GIS communications patch should be loaded (GIS processor checksum = 3CE1).
The spacecraft must be in realtime contact with the EOF during the production of raw files.
The CDS is pointed to a part of the sun in the right Zone for the GSET being produced, and the appropriate slit is selected by commanding the slit motor. A suitable detector High Voltage (HV) is chosen and the GIS is placed into raw data mode (q.v.). (Command CBGRAWN n, where n is the desired detector number).
Selection of raw data mode causes some telemetry parameters to exceed the alarm-limit values. The EOF personnel should be advised that this will happen.
The IDL program “STM” is used to generate the raw files. This software monitors the telemetry stream and produces a raw file whenever it sees that raw data is being sent by the GIS. The name of the generated raw file is displayed within the STM text window. STM can show a pulse-height distribution plot of the raw data. The number of events in the pha data is shown on this plot.
When the file appears to be big enough, the instrument is commanded back to normal mode (CBGNORM). STM then automatically closes off the .raw and .pha files.
A minimum quantity of data must be obtained for satisfactory statistics. The operator should check the sizes of the raw files as they are produced to ensure that the minimum is reached. For the purposes of finding the ideal high voltage a smaller number of events suffices (it is necessary only to determine the shape of the pulse height distribution).
Minimum number of raw events for GSET production = 2,000
Minumum number of raw events for ghost/sensitivity analysis = 10,000.
The pha plot can be monitored continuously to confirm that the desired level has been reached, or the raw file tool XV_RAW (see below) can be used to load the file as it being accumulated.
If for some reason
the GIS communications patch was not loaded (for example following a system
reset or a GIS memory error) then there is a possibility that there will be
interruptions to the raw data stream and that these will cause STM to begin
writing a new raw file. If this occurs, then either disregard the first raw
file if it wasn’t very long and apply the size criteria to the second one, or
use the tool CAT_RAW to join the contents of two raw files, preserving the first one’s
header.
The file distribution procedures[3] currently in place mean that the raw files will be available at certain project institutes (e.g. MSSL) approximately 48 hours following their production.
Several raw data files should be obtained for the purposes of selecting the ideal detector high voltage (HV) level, with the detector being set to a number of HV settings, usually bracketing the current nominal setting. For example if the current HV is C6h, raw files will be taken at HV= (C4h, C6h, C8h).
The detector MCPs produce a broad pulse height distribution whose characteristics depend on the detector high voltage. The mean (peak) of the distribution increases with applied voltage and the relative width (the value of width divided by the centroid value - also known as the “saturation”) tends to decrease with voltage. (The absolute width may increase with voltage). The pulse height distribution is usually shown as a histogram over 256 bins. The GIS works best if the peak of the pulse height distribution is close to the centre of this range.
Observe the detector pulse height distributions in the .pha files, and note which high voltage gives the optimum pulse height distribution - the one with the peak nearest channel 100. There should be at least one file with a voltage that is too low and at least one with an excessively high voltage. Lower voltages should give lower peaks.
The graph should show a central distribution. Other expected features include a step occuring at the position of the low level threshold, and an apparent excess of counts at the upper end of the range. For example:
High Voltage = C1 HV too low |
C6 HV ok |
CB HV too high |
|
|
|
Choose the distribution which has the centroid of the distribution near bin 100. Note the High Voltage that this data was acquired with. This HV will be used in the GSET.
It might be that the range of voltages is not wide enough to bracket the optimum setting. The optimum value cannot really be extrapolated. In this case, more raw data acquisitions should be performed.
The standalone routine VIEW_PHA may be used to view the .pha files. Alternatively the pha data and raw data are shown together by the tool XV_RAW.
Use XV_RAW or VIEW_RAW (or one of its variants) to view a raw file.
XV_RAW is to be preferred -
· automatic retrieval of the raw file associated with a known GSET
· LUT parameters can be adjusted at will (graphical interface vs. VIEW_RAW’s text menus)
· continully shows a quality index[4] of LUT parameters with regard to the current raw file, which assists in LUT optimisation.
· provides r-theta profiles, spectrum display (through MYLUT/USELUT) and other fancy things
However, VIEW_RAW can show the events in forms other than r-theta intensity map, which is currently the only mode of XV_RAW.
At this point the user should have displayed a raw file, and now wishes to optimise the Look-up Table parameters for it. To give an idea of what one should be aiming for, the ideal parameters have been applied to produce the plots in this Table of key GSETs: http://www.mssl.ucl.ac.uk/~mwt/soho/keygsets/keygsets.htm
The parameter values for GSET 42 detector 1 are shown in a table .
This part of the document doesn’t “care” what tool, is used to view the raw files, (obviously the author would hope that you used XV_RAW), therefore the actions are described in general terms.
Note that the set of LUT parameters form part of the instructions given to the GIS software when an on-board LUT is generated. Each parameter occupies one byte in the telecommand, and scaling factors are applied to the parameters expressed in their natural units. This effectively determines the resolution and allowed range of each LUT parameter. See the table “”.
Generally it will be found that the spiral appears to be distorted if all the gains are left at the “neutral” values. These should be adjusted first. When looking at the spiral in the r-theta view the arms should be made as straight as possible. This should be achievable by adjustments of only a few percent. Gain adjustments greater than +-5% are exceptional.
The effect of the gain changes can be visualised as a “pull” on the arms in the directions of 0 (360), 120 and 240 degrees respectively for the x, y, and z gains. Positive adjustment of the gain acts so as to decrease the radius of the arm, i.e. pulls to the left on the conventional r-theta plot.
(diagram)
ZPLN also effects the spiral shape. Generally it is not used (basically because the effects are harder to visualise).
Having tweaked the gains to satisfaction, move on to the LUT geometry. Adjust the value of K so that the lines of the arm boundaries are parallel to the raw-files’s arms. Then, by adjusting the phase Phi, move the arms so that each arm is contained on either side by an arm boundary. Further fine adjustment of the gains may be required at this point. Percent can be adjusted if certain areas need to be avoided (preventing ghosting there) but generally it is left at its maximum (99%) since it is difficult to avoid losing sensitivity in unghosted regions when this is done.
Now set Start and Stop to cover the full range of the data. Either (3.1, 7.3) or (4.1, 8.3) will be used, depending on the phase.
p0 |
p1 |
p2 |
p3 |
p4 |
p5 |
p6 |
p7 |
p8 |
p9 |
p10 |
percent |
stop |
start |
k |
zpln |
phi |
bits |
det
# |
x |
y |
z |
99 |
73 |
31 |
235 |
230 |
0 |
8 |
1 |
96 |
100 |
100 |
Parameter |
Meaning |
Natural Units |
Scaling Factor and Range in Nat units |
Resolution in Natural units i.e. what is the effect of changing
the parameter by one bit |
Gains (x, y, z) |
Orientation of spiral plane with
respect to x, y, z axis |
no adjustment = 1.00 |
100 (0.00 - 2.55) |
0.01 |
ZPLN |
Offset to Sum |
No Adjustment = 0 |
+xxxx |
1 |
K |
rate of spiral r=k*theta theta in radians |
per radian |
100 (0.00 - 2.55) |
0.01 |
Phi |
phase of the spiral theta=theta+phi |
Degrees (0-360) |
256/360 = 0.7111 |
1.4 degrees |
Percent |
fractional arm width used in the table |
%, maximum = 99 |
none |
1% |
Start |
extent of the LUT |
revolutions |
10 (0.0 to 25.5) |
0.1 |
Stop |
e.g. 3.1 to
7.3 |
“ |
e.g. 31 to 73 |
“ |
In general, each GSET contains the best LUT parameters for all four detectors for a given slit and Zone. When preparing a GSET, a raw file should be acquired for each detector and the above optimisation process carried out on each raw file.
The routine MK_GSET is used to enter a new set of LUT parameters in a GSET and store it in the operations database.
It will be recalled that the GIS detector uses a SPAN readout to record the positions of the MCP electron showers. The SPAN readout produces three signals for each event, known as X, Y, and Z. ADCs in the GIS detector electronics record the values of X/(X+Y+Z) and Y/( X+Y+Z).
The raw data file consists of a header, which is identical to the .pha header, followed by a series of pairs of bytes. Each pair of bytes represents the ADC responses to a photon event. The ADCs record the values of X/sum and Y/sum for each event. The size of the file (two bytes per event plus the header) is an indication of the duration of the raw data acquisition.
There are two types of raw data files
1. The pulse height data - extension “.pha”
2. The SPAN ADC (event position list) data - extension “.raw”
These .raw and .pha files are not FITS files. Use GIS_RAW_READ to read the SPAN ADC list (.raw) files. VIEW_PHA may be used to read an plot the PHA files (no standalone routine at present). Both types of file consist mostly of binary data (an event list), however, each file has an ASCII header (512 bytes) that can be viewed with a suitable tool. The headers in .raw and .pha files are identical, and their contents can be viewed, or extracted as a structure, with GIS_RAW_HEADER.
Although both kinds of raw file contain event list data, it is not the case that the same events are measured. Nor is it true that all the events which occur during the acquisition actually get stored in the raw files.
The data files are stored in the directory pointed to by the environment variable CDS_GIS_RAW[5]. The names of the files, which are automatically generated, indicate the time (UT/GMT) of production of the file in the format
yyyyMMDDhhmm_d?_s?.raw or yyyyMMDDhhmm_d?_s?.pha
where ? stands for a single digit - thus “d?” refers to the detector number (1-4) and “s?” refers to the slit number (1-4 are expected[6]) - and the other letters stand for numerical representations of the date, as follows: yyyy = year, MM = month, DD = day, hhmm = time in 24 hour clock (UT). Example: The file 199705131903_d3_s1.raw is an SPAN ADC event list (.raw) for detector 3 and slit 1. The data were recorded on 13th May 1997 at 7:03 pm GMT. The identically named file with a .pha extension is the PHA data for the same time.
[1] On the MSSL unix system this is accomplished as follows:
>solarsw_setup defines solar physics environment variables and aliases
>CIDL defines yet more environment variables and starts IDL, using the CDS startup file.
[2] Experiment Operations Facility
[3] “mirror”
[4] Q=100%*(1-Rejected Fraction)
[5] The (unix) command
$ ls
$CDS_GIS_RAW
will display the raw data files available on the user’s system.
[6] Slits 1 through 6 can be selected, although 4, 5 and 6 are not considered useful (or safe?) for GIS.