API and Modules¶
RECTE module¶
ramp effect model
Version 1.0.0: published version
Version 0.1: Adapted original IDL code (From D. Apai) to python by Yifan Zhou
-
RECTE.
RECTE
(cRates, tExp, exptime=180, trap_pop_s=0, trap_pop_f=0, dTrap_s=0, dTrap_f=0, dt0=0, lost=0, mode='scanning')[source]¶ This function calculates HST/WFC3/IR ramp effect profile based on the charge trapping explanation developed in Zhou et al. (2017).
param cRates: intrinsic count rate of each exposures, unit: e/s type cRates: numpy.array param tExp: time stamps for the exposures, unit: seconds type tExp: numpy.array param exptime: (default 180 seconds) exposure time type exptime: numpy.array or float param trap_pop_s: (default 0) number of occupied slow population charge traps before the very beginning of the observation type trap_pop_s: float or numpy.array param trap_pop_f: (default 0) number of occupied fast population charge traps before the very beginning of the observation type trap_pop_f: float or numpy.array param dTrap_s: (default [0]) number of additional charges trapped by slow population traps during earth occultation type dTrap_s: float or numpy.array param dTrap_f: (default [0]) number of additional charges trapped by fast population traps during earth occultation type dTrap_f: float or numpy.array param dt0: (default 0) exposure time before the very beginning of the observation. It could be due to guidence adjustment type dt0: float param lost: (default 0, no lost) fraction of trapped electrons that are not eventually detected type lost: float param mode: (default scanning, scanning or staring, or others), for scanning mode observation , the pixel no longer receive photons during the overhead time, in staring mode, the pixel keps receiving elctrons type mode: string returns: observed counts rtype: numpy.array Example: see Examples and Cookbook
RECTECorrector module¶
-
RECTECorrector.
RECTECorrector1
(t, orbits, orbits_transit, counts, p, expTime, include_transit=False)[source]¶ correct the ackbar model for one directional scan observations
Parameters: - t – time stamps of the exposures
- orbits – orbit number of the exposures
- orbits_transit – orbits in which transits/eclipses occur
- counts – observed counts
- p – Parameters objects to fit
- expTime – exposure time
Returns: RECTE profile for correciting the light curve, best fit
count rate array, ackbar output, slope :rtype: tuple of four numpy array
-
RECTECorrector.
RECTECorrector2
(t, orbits, orbits_transit, counts, p, expTime, scanDirect)[source]¶ correct the ackbar model for one directional scan observations
Parameters: - t – time stamps of the exposures
- orbits – orbit number of the exposures
- orbits_transit – orbits in which transits/eclipses occur
- counts – observed counts
- p – Parameters objects to fit
- expTime – exposure time
- scanDirect – scan direction (0 or 1) for each exposure
Returns: RECTE profile for correciting the light curve, best fit
count rate array, ackbar output, slope :rtype: tuple of four numpy array
-
RECTECorrector.
rampProfile
(crate, slope, dTrap_s, dTrap_f, trap_pop_s, trap_pop_f, tExp, expTime)[source]¶ Ramp profile for single directional scan
And RECTE model parameters: number of traps, trapping coeeficient and trap life time
Parameters: - crate – average count rate in electron/second
- slope – visit-long slope
- dTrap_s – extra trapped slow charges between orbits
- dTrap_f – extra trapped fast charges between orbits
- trap_pop_s – initially trapped slow charges
- trap_pop_f – initially trapped fast charges
- tExp – beginning of each exposure
- expTime – exposure time
Returns: observed counts
Return type: numpy.array
-
RECTECorrector.
rampProfile2
(crate1, slope1, crate2, slope2, dTrap_s, dTrap_f, trap_pop_s, trap_pop_f, tExp, expTime, scanDirect)[source]¶ Ramp profile for bi-directional scan And ackbar model
Parameters: - crate1 – average count rate in electron/second for the upward direction
- slope1 – visit-long slope for upward direction
- crate2 – average count rate in electron/second for downward direction
- slope2 – visit-long slope for downward direction
- dTrap_s – extra trapped slow charges between orbits
- dTrap_f – extra trapped fast charges between orbits
- trap_pop_s – initially trapped slow charges
- trap_pop_f – initially trapped fast charges
- tExp – beginning of each exposure
- expTime – exposure time
- scanDirect – scan direction (0 or 1) for each exposure
Returns: observed counts
Return type: numpy.array