ecpi.common.instru.model_effect module¶
Section author: ECLAIRs GP team
Treatment of detector effects
Summary¶
Classes:
Implementation of detector effects (ARF, IRF, RMF) |
|
Default class of ECLAIRsDetectorEffect |
Class diagram:
Functions:
return idx of the first zero |
Reference¶
-
class
ECLAIRsDetectorEffect[source]¶ Bases:
objectImplementation of detector effects (ARF, IRF, RMF)
-
property
chan_boundary¶
-
property
chan_center¶
-
property
chan_step¶
-
compute_globalefficiency()[source]¶ Compute global efficiency defined as the elementwise product between efficiency and non uniformity matrices.
-
get_energymax_val(chan)[source]¶ Return energy value in a given channel index.
- Parameters
chan (int) – upper channel index
- Returns
energy value
- Return type
float
-
get_energymin_val(chan)[source]¶ Return energy value in a given channel index.
- Parameters
chan (int) – lower channel index
- Returns
energy value
- Return type
float
-
get_irf_array_ijecpi()[source]¶ Return raw IRF array from EIC
- Returns
raw IRF array, ie IRF value for pixel center in array 199x199
- Return type
2D numpy array 199x199
-
get_irf_val_ecllos(y_pix, z_pix, channel=None, ngp=False)[source]¶ Return IRF value at position with ECLLos referential in pixel unit
Warning
problem with border with array 199x199 ? Need to extrapolate ?
- Parameters
y_pix (float) – y position in ECLLos referential in pixel unit
:param z_pix:z position in ECLLos referential in pixel unit :type z_pix: float :param channel: Energy channel index in EIC convention. Default is None. :type channel: int :param ngp: flag to opt for the Nearest Grid Position algorithm. Default is False. :type ngp: bool :param verbose: flag to enable/disable printing of the IRF coeff value. Default is False. :type verbose: bool :return: value of IRF at (y_pix, z_pix) :rtype: float
-
get_list_rv_rmf()[source]¶ return a list of generator object for each channel
- Returns
list of generator object for each channel
- Return type
generator object is an instance of scipy.stats.rv_discrete
-
get_rmf_max_channel_def(channel)[source]¶ return channel where rmf becomes and stay to zero :return: index of first zero on distribution :rtype: int
-
get_rmf_norm(channel)[source]¶ Normalize rmf distribution :return: rmf normalize :rtype: numpy array
-
set_arf(path_arf)[source]¶ Set ARF related attributes from file path
- Parameters
path_arf (str) – path to ARF file
-
set_efficiency(path_efficiency)[source]¶ Set detector efficiency from file path.
- Parameters
path_efficiency (str) – path to detector efficiency file
-
set_irf(path_irf)[source]¶ Set IRF related attributes from file path
- Parameters
path_irf (str) – path to IRF file
-
set_nonuniformity(path_nonuniformity)[source]¶ Set detector non uniformity from file path.
- Parameters
path_nonuniformity (str) – path to detector efficiency file
-
property
-
class
ECLAIRsDetectorEffectDefault[source]¶ Bases:
ecpi.common.instru.model_effect.ECLAIRsDetectorEffectDefault class of ECLAIRsDetectorEffect