forked from fermi-lat/fermitools-fhelp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgtdrm.txt
130 lines (95 loc) · 4.87 KB
/
gtdrm.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
NAME
gtdrm - Write the energy dispersion matrix
USAGE
gtdrm cmap outfile irfs evtype expcube bexpmap
DESCRIPTION
The detector response matrix (DRM) maps the true counts spectrum to the
measured counts spectrum. It is computed by taking the integrals of the
energy dispersion across each measured energy bin assuming the true energy
is the geometric mean of each bin. This is a approximation, the exact
computation would require the convolution integral of product of the
spectrum with the effective area and the energy dispersion.
The individual elements of the DRM are computed in
Drm::matrix_element(double etrue, double emeas_min, double emeas_max), which
computes the fraction of counts with etrue that are observed in the energy
bin between emeas_min and emeas_max.
This is evaluated with emeas_min, emeas_max corresponding to each of the
energy bin edges, and with etrue corresponding to the geometric centers of
the energy bins, and extended to one extra bin on either end of the
spectrum.
This means that the Drm is a (n,n+2) matrix, where n is the number of
measured energy bin (i.e., the number of energy bins in the binned counts
cube).
PARAMETERS
cmap [file]
Source maps (or counts map) file.
outfile [file]
Output FITS file name.
irfs [string]
Instrument response functions. The instrument response (PSF, effective
area, energy resolution) is currently a function of energy,
inclination angle (the angle between the source and the LAT normal)
and photon category. Since the LAT will usually survey the sky, a
source will be observed at different inclination angles. Each count
will therefore be characterized by a different instrument response
function (IRF). The default value is “CALDB”.
(evtype = INDEF) [integer]
The event type selection for Pass 8 data. The event type is a subselection
of the event class. Users can select on range of events based on conversion
type (front/back), angular reconstruction quality (PSF values), and energy
reconstruction quality (EDISP values). The default value is INDEF, which
will not apply a subselection.
expcube [file]
FITS file containing live-time as a function of sky position and off-axis
angle. This file should be generated by gtltcube. See the gtltcube
documentation for further explanation.
bexpmap [file]
Exposure map for binned analysis. The geometry of the map must match
the geometry of the counts map. Only for binned likelihood analysis.
Default is "none".
(chatter = 2) [integer]
This parameter fixes the output verbosity: no screen output (0), nominal
screen output (2), maximum verbosity (4). The default value is 2.
(clobber = yes) [boolean]
Overwrite or do not overwrite existing output files. This is a hidden
parameter. The default value is "yes".
(debug = no) [boolean]
Activate debugging mode. This is a hidden parameter. The default value is
"no". When debug is "no", all exceptions that are not caught and handled by
individual tool-specific code are caught by a top-level exception handler
that displays information about the exception and then exits. When debug is
"yes", such exceptions are not caught by the top level code. Instead the
tool produces a segmentation violation, which is more useful for debugging.
When debugging mode is enabled, the tool produces more verbose output
describing any errors or exceptions that are encountered.
(gui = no) [boolean]
Graphical user Interface (GUI) mode activated is "yes" is specified. This
is a hidden parameter. The default value is "no".
(mode = ql) [string]
Mode of automatic parameters. This is a hidden parameter. The default
value is "ql".
EXAMPLES
Parameters are passed following the FTOOLs model: They could be passed
answering from a prompt, as a list in a command line, or by editing
the parameter file.
To run gtdrm simply type in the command line:
> gtdrm
This will prompt for parameter values. Not all parameter are prompted:
some of them are "hidden". To change one of the "hidden" parameter,
the user should specify the values in the command line or modify its
mode by editing the parameter file.
For example, to prevent overwrite the existing output file, the following
command line as to be typed:
> gtdrm clobber=no
An example of how to run the tool is given below:
> gtdrm
Source maps (or counts map) file[] cmap.fits
Output file[] drm.fits
Response functions[CALDB] CALDB
Exposure cube[] expcube.fits
Binned exposure map[none] bexposure.fits
That last example could be also run in the command line as follows:
gtdrm cmap=srcMaps.fits outfile=drm.fits
irfs=CALDB expcube=expCube.fits bexpmap=bexposure.fits
SEE ALSO
gtlike