Open TheNovusCoder opened 3 weeks ago
From Albert: The corrected rates are not in the FITS file, so we would need to re-implement the algorithm in Python.
My description of the algorithm from the thread:
... RHESSI has attenuators that are moved in and out to moderate the incident flux. ... The normal or “uncorrected” quicklook lightcurves are merely showing the attenuators doing their job.
It is not possible to accurately correct the rates for the changing attenuator states without a spectral model, which formally requires a careful analysis of the flare spectrum and the underlying background. Instead, for quicklook rates, the “corrected” quicklook rates are calculated using a heuristic algorithm that essentially scales each lightcurve segment so that the overall result looks continuous. However, this correction approach is intended only for qualitative use because it is not scientifically robust: the algorithm can get misled if there is a real transition/burst close to an attenuator-state change, resulting in short artifacts or even long-term scaling errors.
The relevant IDL code (not for the faint of heart!) is in these files:
https://hesperia.gsfc.nasa.gov/ssw/hessi/idl/qlook_archive/hsi_obs_summ_rate__define.pro https://hesperia.gsfc.nasa.gov/ssw/hessi/idl/qlook_archive/hsi_ql_atten_correct.pro https://hesperia.gsfc.nasa.gov/ssw/hessi/idl/qlook_archive/hsi_ql_front_decimation_correct.pro https://hesperia.gsfc.nasa.gov/ssw/hessi/idl/qlook_archive/hsi_ql_rear_decimation_correct.pro https://hesperia.gsfc.nasa.gov/ssw/hessi/idl/qlook_archive/hsi_old_rear_decimation_correct.pro
Describe the feature
Hi. You can refer to the issue here in my chat with ayshih. I noticed that there is no feature in SunPy to plot the "Corrected" RHESSI Hard X-Ray emission light curve. It would be useful to have it. Thank you.