sccala.asynphot.aks_correction
Functions
|
|
|
|
|
|
|
|
|
Unred spectra with Fitzenpatrick 2019 |
|
|
|
Do a full AKS correction on input photometry. Corrects any number of |
Module Contents
- sccala.asynphot.aks_correction.get_sn_info(snname, modelpath='Models')
- sccala.asynphot.aks_correction.get_sn_phot(photometry_file)
- sccala.asynphot.aks_correction.get_sn_spectra(snname, delimiter=',', modelpath='Models', check_spectra=True, rej_100=True)
- sccala.asynphot.aks_correction.mag_interp(mjd, mag, emag, spec_epoch, band=None, visualize=True)
- sccala.asynphot.aks_correction.f19_unred(wave, flux, av, **kwargs)
Unred spectra with Fitzenpatrick 2019 Only uses Milky Way E(B-V), ignoring host galaxy extinction Assumes R_V = 3.1 per default
- sccala.asynphot.aks_correction.warp_spectrum(offset, lambda_effs, wav, flux, filters, kind='linear')
- sccala.asynphot.aks_correction.aks_correction(snname, photometry_file, filter_in, filter_out, output=None, modelpath='Models', epoch_region=None, lsb=[0.0, 0.0], maxiter=10, save_plots=True, save_results=True, delimiter=',', disable_mean_fit=False, inspect_phot_interp=False)
Do a full AKS correction on input photometry. Corrects any number of input filter bands to specified output filter bands. Only works if the input photometry only consits of photometry taken by the same instrument. Using multiple instruments might lead to unexpected results.
Parameters
- snnamestr
Name of the SN to be corrected. The model spectra used in the correction need to be stored under the same name in the model directory specified by the modelpath option.
- photometry_filestr
Path to the input file containing the photometry data. Data should be formatted similar to the output files of the OSC.
- filter_instr
Path to a text file containing the names of the intput filters which are to be used for the correction.
- filter_outstr
Path to a text file containing the names of the output filters which are to be used for the correction.
- outputstr
Name of the output file where the corrected photometry is stored. Default: None
- modelpathstr
Path of the direcotry where the model spectra used in the correction. Should have a similar directory structure to the Data directory. Default: ‘Models’
- epoch_regionlist or Tuple
Epoch range from which input photometry is considered. Data outside this range is discarded. Default: None
- lsblist or Tuple
Extrapolation rules to consider spectra outside the specified epoch_range. Default: ‘[0.0, 0.0]’
- maxiterint
Maximum number of iteration to adjust flux density to match observed photometry.
- save_plotsbool
If True, diagnostic plots showing interpolated AKS correction values will be saved in the diagnostic directory. Default: True
- save_resultsbool
If True, detailed AKS correction results will be stored in the results directory. A separate file will be stored for each filter band. Default: True
- delimiterstr
Delimiter used in the model spectra. Default: ‘,’
- disable_mean_fitbool
If True, mean fit will be disabled in photometry interpolation. Default: False
- inspect_phot_interpbool
If True, interactive plots will be show to verify that photometry was interpolated correctly. Default: False
Returns
aks_corr_phot, aks_corr_phot_err