def default_pypeit_par(self): """ Set default parameters for magellan MagE reduction. """ par = pypeitpar.PypeItPar() par['rdx']['spectrograph'] = 'magellan_mage' # Frame numbers par['calibrations']['standardframe']['number'] = 1 par['calibrations']['biasframe']['number'] = 0 par['calibrations']['pixelflatframe']['number'] = 3 par['calibrations']['traceframe']['number'] = 3 par['calibrations']['arcframe']['number'] = 1 # Bias par['calibrations']['biasframe']['useframe'] = 'overscan' # Wavelengths # 1D wavelength solution par['calibrations']['wavelengths'][ 'rms_threshold'] = 0.20 # Might be grating dependent.. par['calibrations']['wavelengths']['sigdetect'] = 5.0 par['calibrations']['wavelengths']['lamps'] = ['ThAr'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[ 0]['nonlinear'] * self.detector[0]['saturation'] #par['calibrations']['wavelengths']['method'] = 'reidentify' # Reidentification parameters #par['calibrations']['wavelengths']['reid_arxiv'] = 'magellan_thar.json' par['calibrations']['wavelengths']['ech_fix_format'] = True # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 4 par['calibrations']['wavelengths']['ech_norder_coeff'] = 4 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' # Set slits and tilts parameters # par['calibrations']['tilts']['order'] = 2 par['calibrations']['tilts']['tracethresh'] = [ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10 ] par['calibrations']['slits']['trace_npoly'] = 5 par['calibrations']['slits']['maxshift'] = 3. par['calibrations']['slits']['pcatype'] = 'order' # Scienceimage default parameters par['scienceimage'] = pypeitpar.ScienceImagePar() # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Do not correct for flexure par['flexure'] = pypeitpar.FlexurePar() par['flexure']['method'] = 'skip' # Set the default exposure time ranges for the frame typing par['calibrations']['standardframe']['exprng'] = [None, 20] par['calibrations']['arcframe']['exprng'] = [20, None] par['calibrations']['darkframe']['exprng'] = [20, None] par['scienceframe']['exprng'] = [20, None] return par
def default_pypeit_par(self): """ Set default parameters for magellan MagE reduction. """ par = pypeitpar.PypeItPar() par['rdx']['spectrograph'] = 'magellan_mage' # Bias #par['calibrations']['biasframe']['useframe'] = 'overscan' # Wavelengths # 1D wavelength solution par['calibrations']['wavelengths'][ 'rms_threshold'] = 0.20 # Might be grating dependent.. par['calibrations']['wavelengths']['sigdetect'] = 5.0 par['calibrations']['wavelengths']['lamps'] = ['ThAr_MagE'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[ 0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['method'] = 'reidentify' par['calibrations']['wavelengths']['cc_thresh'] = 0.50 par['calibrations']['wavelengths']['cc_local_thresh'] = 0.50 # Reidentification parameters par['calibrations']['wavelengths']['reid_arxiv'] = 'magellan_mage.fits' par['calibrations']['wavelengths']['ech_fix_format'] = True # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 4 par['calibrations']['wavelengths']['ech_norder_coeff'] = 4 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' # Set slits and tilts parameters par['calibrations']['tilts']['tracethresh'] = [10] * self.norders par['calibrations']['slitedges']['fit_order'] = 5 par['calibrations']['slitedges']['max_shift_adj'] = 3. par['calibrations']['slitedges'][ 'edge_thresh'] = 10. # Tough to get the bluest orders par['calibrations']['slitedges']['left_right_pca'] = True par['calibrations']['slitedges'][ 'fit_min_spec_length'] = 0.3 # Allow for a short detected blue order # Find object parameters par['scienceimage']['findobj']['find_trim_edge'] = [ 4, 4 ] # Slit is too short to trim 5,5 especially with 2x binning # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Do not correct for flexure par['flexure'] = pypeitpar.FlexurePar() par['flexure']['method'] = 'skip' # Set the default exposure time ranges for the frame typing par['calibrations']['standardframe']['exprng'] = [None, 20] par['calibrations']['arcframe']['exprng'] = [20, None] par['calibrations']['darkframe']['exprng'] = [20, None] par['scienceframe']['exprng'] = [20, None] return par
def default_pypeit_par(): """ Set default parameters for Keck LRISb reductions. """ par = pypeitpar.PypeItPar() par['rdx']['spectrograph'] = 'wht_isis_blue' # Set pixel flat combination method par['calibrations']['pixelflatframe']['process']['combine'] = 'median' par['calibrations']['pixelflatframe']['process']['sig_lohi'] = [10.,10.] # Change the wavelength calibration method par['calibrations']['wavelengths']['method'] = 'simple' # Scienceimage default parameters par['scienceimage'] = pypeitpar.ScienceImagePar() # Do not flux calibrate par['fluxcalib'] = None # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing par['calibrations']['biasframe']['exprng'] = [None, 1] par['calibrations']['darkframe']['exprng'] = [999999, None] # No dark frames par['calibrations']['pinholeframe']['exprng'] = [999999, None] # No pinhole frames par['calibrations']['arcframe']['exprng'] = [None, 120] par['calibrations']['standardframe']['exprng'] = [None, 120] par['scienceframe']['exprng'] = [90, None] return par
def default_pypeit_par(): """ Set default parameters for Keck LRISb reductions. """ par = pypeitpar.PypeItPar() # Set wave tilts order par['calibrations']['slits']['sigdetect'] = 20. par['calibrations']['slits']['trace_npoly'] = 3 # TODO: No longer a parameter # par['calibrations']['slits']['fracignore'] = 0.02 # par['calibrations']['slits']['pcapar'] = [3,2,1,0] # 1D wavelength solution par['calibrations']['wavelengths']['rms_threshold'] = 0.40 # Might be grating dependent.. par['calibrations']['wavelengths']['sigdetect'] = 5. # Doesn't work for reddest chip par['calibrations']['wavelengths']['lamps'] = ['CuI', 'ArI', 'ArII'] # Overscan subtract the images #par['calibrations']['biasframe']['useframe'] = 'overscan' # Alter the method used to combine pixel flats par['calibrations']['pixelflatframe']['process']['combine'] = 'median' par['calibrations']['pixelflatframe']['process']['sig_lohi'] = [10.,10.] # Scienceimage default parameters par['scienceimage'] = pypeitpar.ScienceImagePar() # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing #par['scienceframe']['exprng'] = [30, None] return par
def default_pypeit_par(): """ Set default parameters for LBT/LUCI reductions. OLD CODE from LBT MODS """ par = pypeitpar.PypeItPar() # Scienceimage default parameters par['reduce'] = pypeitpar.ReducePar() # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibratePar() # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing par['calibrations']['biasframe']['exprng'] = [None, 1] par['calibrations']['darkframe']['exprng'] = [999999, None] # No dark frames par['calibrations']['pinholeframe']['exprng'] = [999999, None ] # No pinhole frames par['calibrations']['pixelflatframe']['exprng'] = [0, None] par['calibrations']['traceframe']['exprng'] = [0, None] par['calibrations']['arcframe']['exprng'] = [None, 60] par['calibrations']['standardframe']['exprng'] = [1, 200] par['scienceframe']['exprng'] = [200, None] return par
def default_pypeit_par(): """ Set default parameters for Shane Kast reductions. """ par = pypeitpar.PypeItPar() # Frame numbers par['calibrations']['standardframe']['number'] = 1 par['calibrations']['biasframe']['number'] = 5 par['calibrations']['pixelflatframe']['number'] = 5 par['calibrations']['traceframe']['number'] = 5 par['calibrations']['arcframe']['number'] = 1 # Scienceimage default parameters par['scienceimage'] = pypeitpar.ScienceImagePar() # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing par['calibrations']['biasframe']['exprng'] = [None, 1] par['calibrations']['darkframe']['exprng'] = [999999, None] # No dark frames par['calibrations']['pinholeframe']['exprng'] = [999999, None ] # No pinhole frames par['calibrations']['pixelflatframe']['exprng'] = [0, None] par['calibrations']['traceframe']['exprng'] = [0, None] par['calibrations']['arcframe']['exprng'] = [None, 60] par['calibrations']['standardframe']['exprng'] = [1, 200] par['scienceframe']['exprng'] = [200, None] return par
def default_pypeit_par(): """ Set default parameters for KECK HIRES reductions. """ par = pypeitpar.PypeItPar() # Correct for flexure using the default approach par['flexure'] = pypeitpar.FlexurePar() return par
def default_pypeit_par(cls): """ Return the default parameters to use for this instrument. Returns: :class:`~pypeit.par.pypeitpar.PypeItPar`: Parameters required by all of ``PypeIt`` methods. """ par = super().default_pypeit_par() # Correct for flexure using the default approach par['flexure'] = pypeitpar.FlexurePar() return par
def default_pypeit_par(self): """ Set default parameters for Keck LRISb reductions. """ par = pypeitpar.PypeItPar() par['rdx']['spectrograph'] = 'keck_deimos' # Set wave tilts order par['calibrations']['slits']['sigdetect'] = 50. par['calibrations']['slits']['trace_npoly'] = 3 par['calibrations']['slits']['fracignore'] = 0.02 par['calibrations']['slits']['pcapar'] = [3, 2, 1, 0] # Overscan subtract the images par['calibrations']['biasframe']['useframe'] = 'overscan' # 1D wavelength solution par['calibrations']['wavelengths']['lamps'] = [ 'ArI', 'NeI', 'KrI', 'XeI' ] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[ 0]['nonlinear'] * self.detector[0]['saturation'] # Alter the method used to combine pixel flats par['calibrations']['pixelflatframe']['process']['combine'] = 'median' par['calibrations']['pixelflatframe']['process']['sig_lohi'] = [ 10., 10. ] # Scienceimage default parameters par['scienceimage'] = pypeitpar.ScienceImagePar() # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing par['calibrations']['biasframe']['exprng'] = [None, 2] par['calibrations']['darkframe']['exprng'] = [999999, None] # No dark frames par['calibrations']['pinholeframe']['exprng'] = [999999, None ] # No pinhole frames par['calibrations']['pixelflatframe']['exprng'] = [None, 30] par['calibrations']['traceframe']['exprng'] = [None, 30] par['scienceframe']['exprng'] = [30, None] # LACosmics parameters par['scienceframe']['process']['sigclip'] = 4.0 par['scienceframe']['process']['objlim'] = 1.5 return par
def default_pypeit_par(): """ Set default parameters for TNG Dolores reductions. """ par = pypeitpar.PypeItPar() #par['calibrations']['tilts']['params'] = [1,1,1] # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing par['calibrations']['biasframe']['exprng'] = [None, 0.1] par['calibrations']['darkframe']['exprng'] = [999999, None] # No dark frames par['calibrations']['pinholeframe']['exprng'] = [999999, None] # No pinhole frames par['scienceframe']['exprng'] = [1, None] return par
def default_pypeit_par(): """ Set default parameters for Keck LRISb reductions. """ par = pypeitpar.PypeItPar() par['calibrations']['slitedges']['edge_thresh'] = 20. par['calibrations']['slitedges']['fit_order'] = 3 # 1D wavelength solution par['calibrations']['wavelengths'][ 'rms_threshold'] = 0.40 # Might be grating dependent.. par['calibrations']['wavelengths'][ 'sigdetect'] = 5. # Doesn't work for reddest chip par['calibrations']['wavelengths']['lamps'] = ['CuI', 'ArI', 'ArII'] par['calibrations']['wavelengths']['method'] = 'full_template' par['calibrations']['wavelengths'][ 'nsnippet'] = 1 # 3 detectors splitting is already a lot par['calibrations']['tilts'][ 'tracethresh'] = 10. # Deals with faint CuAr lines # IF YOU CHANGE THIS, YOU WILL NEED TO DEAL WITH THE OVERSCAN GOING ALONG ROWS #for key in par['calibrations'].keys(): # if 'frame' in key: # par['calibrations'][key]['process']['overscan'] = 'median' # Overscan subtract the images #par['calibrations']['biasframe']['useframe'] = 'overscan' # Alter the method used to combine pixel flats par['calibrations']['pixelflatframe']['process']['combine'] = 'median' par['calibrations']['pixelflatframe']['process']['sig_lohi'] = [ 10., 10. ] # Always flux calibrate, starting with default parameters par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Always correct for flexure, starting with default parameters par['flexure']['method'] = 'boxcar' # Set the default exposure time ranges for the frame typing #par['scienceframe']['exprng'] = [30, None] return par
def default_pypeit_par(self): """ Set default parameters for Keck LRISb reductions. """ par = pypeitpar.PypeItPar() par['rdx']['spectrograph'] = 'wht_isis_blue' # Ignore PCA par['calibrations']['slitedges']['sync_predict'] = 'nearest' # Turn off the overscan for ftype in par['calibrations'].keys(): try: par['calibrations'][ftype]['process']['overscan'] = 'none' except (TypeError, KeyError): pass par['scienceframe']['process']['overscan'] = 'none' # Make a bad pixel mask par['calibrations']['bpm_usebias'] = True # Set pixel flat combination method par['calibrations']['pixelflatframe']['process']['combine'] = 'median' par['calibrations']['pixelflatframe']['process']['sig_lohi'] = [10.,10.] # Change the wavelength calibration method par['calibrations']['wavelengths']['method'] = 'full_template' par['calibrations']['wavelengths']['lamps'] = ['NeI', 'ArI', 'ArII', 'CuI'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['n_first'] = 3 par['calibrations']['wavelengths']['n_final'] = 5 par['calibrations']['wavelengths']['sigdetect'] = 10.0 par['calibrations']['wavelengths']['wv_cen'] = 4859.0 par['calibrations']['wavelengths']['disp'] = 0.2 # Do not flux calibrate par['fluxcalib'] = None # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Set the default exposure time ranges for the frame typing par['calibrations']['biasframe']['exprng'] = [None, 1] par['calibrations']['darkframe']['exprng'] = [999999, None] # No dark frames par['calibrations']['pinholeframe']['exprng'] = [999999, None] # No pinhole frames par['calibrations']['arcframe']['exprng'] = [None, 120] par['calibrations']['standardframe']['exprng'] = [None, 120] par['scienceframe']['exprng'] = [90, None] return par
def default_pypeit_par(cls): """ Return the default parameters to use for this instrument. Returns: :class:`~pypeit.par.pypeitpar.PypeItPar`: Parameters required by all of ``PypeIt`` methods. """ par = super().default_pypeit_par() # Adjustments to slit and tilts for NIR par['calibrations']['slitedges']['edge_thresh'] = 600. par['calibrations']['slitedges']['fit_order'] = 5 par['calibrations']['slitedges']['max_shift_adj'] = 0.5 par['calibrations']['slitedges']['left_right_pca'] = True par['calibrations']['tilts']['tracethresh'] = 20 # Bias par['calibrations']['biasframe']['useframe'] = 'bias' # 1D wavelength solution par['calibrations']['wavelengths']['lamps'] = ['ThAr'] #par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['rms_threshold'] = 0.25 par['calibrations']['wavelengths']['sigdetect'] = 5.0 # Reidentification parameters #par['calibrations']['wavelengths']['method'] = 'reidentify' #par['calibrations']['wavelengths']['reid_arxiv'] = 'vlt_xshooter_nir.json' par['calibrations']['wavelengths']['ech_fix_format'] = True # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 4 par['calibrations']['wavelengths']['ech_norder_coeff'] = 4 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' par['calibrations']['standardframe']['exprng'] = [None, 600] par['scienceframe']['exprng'] = [600, None] return par
def default_pypeit_par(self): """ Set default parameters for HIRES RED reductions. """ par = KECKHIRESSpectrograph.default_pypeit_par() par['rdx']['spectrograph'] = 'keck_hires_red' # Adjustments to slit and tilts for NIR par['calibrations']['slitedges']['edge_thresh'] = 600. par['calibrations']['slitedges']['fit_order'] = 5 par['calibrations']['slitedges']['max_shift_adj'] = 0.5 par['calibrations']['slitedges']['left_right_pca'] = True par['calibrations']['tilts']['tracethresh'] = 20 # Bias par['calibrations']['biasframe']['useframe'] = 'bias' # 1D wavelength solution par['calibrations']['wavelengths']['lamps'] = ['ThAr'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[ 0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['rms_threshold'] = 0.25 par['calibrations']['wavelengths']['sigdetect'] = 5.0 # Reidentification parameters #par['calibrations']['wavelengths']['method'] = 'reidentify' #par['calibrations']['wavelengths']['reid_arxiv'] = 'vlt_xshooter_nir.json' par['calibrations']['wavelengths']['ech_fix_format'] = True # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 4 par['calibrations']['wavelengths']['ech_norder_coeff'] = 4 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' par['calibrations']['standardframe']['exprng'] = [None, 600] par['scienceframe']['exprng'] = [600, None] return par
def default_pypeit_par(): """ Set default parameters for NIRSPEC reductions """ par = pypeitpar.PypeItPar() # Frame numbers par['calibrations']['standardframe']['number'] = 1 par['calibrations']['biasframe']['number'] = 0 par['calibrations']['pixelflatframe']['number'] = 5 par['calibrations']['traceframe']['number'] = 5 par['calibrations']['arcframe']['number'] = 1 # Scienceimage default parameters par['scienceimage'] = pypeitpar.ScienceImagePar() # Do not flux calibrate # NIRSPEC uses sky lines to wavelength calibrate; no need for flexure correction par['flexure'] = pypeitpar.FlexurePar() par['flexure']['method'] = 'skip' # Set the default exposure time ranges for the frame typing par['calibrations']['arcframe']['exprng'] = [1, None] par['calibrations']['biasframe']['exprng'] = [None, 2] par['calibrations']['darkframe']['exprng'] = [None, 5] par['calibrations']['pinholeframe']['exprng'] = [999999, None] # No pinhole frames par['calibrations']['pixelflatframe']['exprng'] = [0, None] par['calibrations']['traceframe']['exprng'] = [0, None] par['calibrations']['standardframe']['exprng'] = [None,5] par['scienceframe']['exprng'] = [1, None] # Lower the default threshold for tilts par['calibrations']['tilts']['tracethresh'] = 10. # Slits par['calibrations']['slits']['sigdetect'] = 200. # 1D wavelength solution par['calibrations']['wavelengths']['lamps'] = ['OH_R24000'] par['calibrations']['wavelengths']['rms_threshold'] = 0.20 # Good for NIRSPEC-1 par['calibrations']['wavelengths']['sigdetect'] = 5. # Good for NIRSPEC-1 return par
def default_pypeit_par(self): """ Set default parameters for XSHOOTER NIR reductions. """ par = VLTXShooterSpectrograph.default_pypeit_par() par['rdx']['spectrograph'] = 'vlt_xshooter_nir' # Adjustments to slit and tilts for NIR par['calibrations']['slits']['sigdetect'] = 120. par['calibrations']['slits']['trace_npoly'] = 8 par['calibrations']['slits']['maxshift'] = 0.5 # Tilt parameters par['calibrations']['tilts']['tracethresh'] = 25.0 par['calibrations']['tilts']['maxdev_tracefit'] = 0.04 par['calibrations']['tilts']['maxdev2d'] = 0.04 par['calibrations']['tilts']['spat_order'] = 3 par['calibrations']['tilts']['spec_order'] = 4 # 1D wavelength solution par['calibrations']['wavelengths']['lamps'] = ['OH_XSHOOTER'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['rms_threshold'] = 0.25 par['calibrations']['wavelengths']['sigdetect'] = 10.0 par['calibrations']['wavelengths']['fwhm'] = 5.0 par['calibrations']['wavelengths']['n_final'] = 4 # Reidentification parameters par['calibrations']['wavelengths']['method'] = 'reidentify' par['calibrations']['wavelengths']['reid_arxiv'] = 'vlt_xshooter_nir.json' par['calibrations']['wavelengths']['cc_thresh'] = 0.50 par['calibrations']['wavelengths']['cc_local_thresh'] = 0.50 par['calibrations']['wavelengths']['ech_fix_format'] = True # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 5 par['calibrations']['wavelengths']['ech_norder_coeff'] = 5 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Flats par['calibrations']['flatfield']['illumflatten'] = False par['calibrations']['flatfield']['tweak_slits_thresh'] = 0.90 par['calibrations']['flatfield']['tweak_slits_maxfrac'] = 0.10 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Is this needed below? par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' # TODO tune up LA COSMICS parameters here for X-shooter as tellurics are being excessively masked # Extraction par['scienceimage']['bspline_spacing'] = 0.8 par['scienceimage']['model_full_slit'] = True # local sky subtraction operates on entire slit par['scienceimage']['global_sky_std'] = False # Do not perform global sky subtraction for standard stars par['scienceimage']['trace_npoly'] = 8 # Do not bias subtract par['scienceframe']['useframe'] ='none' # This is a hack for now until we can specify for each image type what to do. Bias currently # controls everything par['calibrations']['biasframe']['useframe'] = 'none' return par
def default_pypeit_par(self): """ Set default parameters for Shane Kast Blue reductions. """ par = pypeitpar.PypeItPar() par['rdx']['spectrograph'] = 'magellan_fire' # No overscan for key in par['calibrations'].keys(): if 'frame' in key: par['calibrations'][key]['process']['overscan'] = 'none' # Wavelengths # 1D wavelength solution with OH lines par['calibrations']['wavelengths']['rms_threshold'] = 1.0 par['calibrations']['wavelengths']['sigdetect'] = [ 5, 10, 10, 10, 10, 20, 30, 30, 30, 30, 30, 10, 30, 30, 60, 30, 30, 10, 20, 30, 10 ] par['calibrations']['wavelengths']['n_first'] = 2 par['calibrations']['wavelengths']['n_final'] = [ 3, 3, 3, 2, 4, 4, 4, 3, 4, 4, 4, 3, 4, 4, 4, 4, 4, 4, 6, 6, 4 ] par['calibrations']['wavelengths']['lamps'] = ['OH_FIRE_Echelle'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[ 0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['method'] = 'reidentify' par['calibrations']['wavelengths']['cc_thresh'] = 0.35 par['calibrations']['wavelengths'][ 'reid_arxiv'] = 'magellan_fire_echelle.fits' par['calibrations']['wavelengths']['match_toler'] = 30.0 # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_fix_format'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 4 par['calibrations']['wavelengths']['ech_norder_coeff'] = 6 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' # Set slits and tilts parameters par['calibrations']['tilts']['tracethresh'] = 5 par['calibrations']['slitedges']['edge_thresh'] = 10. par['calibrations']['slitedges']['trace_thresh'] = 10. par['calibrations']['slitedges']['fit_order'] = 5 par['calibrations']['slitedges']['max_shift_adj'] = 0.5 par['calibrations']['slitedges']['fit_min_spec_length'] = 0.5 par['calibrations']['slitedges']['left_right_pca'] = True par['calibrations']['slitedges']['pca_order'] = 3 # Scienceimage default parameters par['reduce'] = pypeitpar.ReducePar() # Always flux calibrate, starting with default parameters #par['fluxcalib'] = pypeitpar.FluxCalibrationPar() # Do not correct for flexure par['flexure'] = None # Set the default exposure time ranges for the frame typing par['calibrations']['standardframe']['exprng'] = [None, 60] par['calibrations']['arcframe']['exprng'] = [20, None] par['calibrations']['darkframe']['exprng'] = [20, None] par['scienceframe']['exprng'] = [20, None] # Sensitivity function parameters # Sensitivity function parameters par['sensfunc']['algorithm'] = 'IR' par['sensfunc']['polyorder'] = 8 # place holder for telgrid file par['sensfunc']['IR']['telgridfile'] = resource_filename( 'pypeit', '/data/telluric/TelFit_MaunaKea_3100_26100_R20000.fits') return par
def default_pypeit_par(self): """ Set default parameters for XSHOOTER NIR reductions. """ par = VLTXShooterSpectrograph.default_pypeit_par() par['rdx']['spectrograph'] = 'vlt_xshooter_nir' # Adjustments to slit and tilts for NIR par['calibrations']['slitedges']['edge_thresh'] = 50. par['calibrations']['slitedges']['fit_order'] = 8 par['calibrations']['slitedges']['max_shift_adj'] = 0.5 par['calibrations']['slitedges']['trace_thresh'] = 10. par['calibrations']['slitedges']['fit_min_spec_length'] = 0.5 par['calibrations']['slitedges']['left_right_pca'] = True par['calibrations']['slitedges']['length_range'] = 0.3 # Tilt parameters par['calibrations']['tilts']['rm_continuum'] = True par['calibrations']['tilts']['tracethresh'] = 25.0 par['calibrations']['tilts']['maxdev_tracefit'] = 0.04 par['calibrations']['tilts']['maxdev2d'] = 0.04 par['calibrations']['tilts']['spat_order'] = 3 par['calibrations']['tilts']['spec_order'] = 4 # 1D wavelength solution par['calibrations']['wavelengths']['lamps'] = ['OH_XSHOOTER'] par['calibrations']['wavelengths']['nonlinear_counts'] = self.detector[ 0]['nonlinear'] * self.detector[0]['saturation'] par['calibrations']['wavelengths']['rms_threshold'] = 0.25 par['calibrations']['wavelengths']['sigdetect'] = 10.0 par['calibrations']['wavelengths']['fwhm'] = 5.0 par['calibrations']['wavelengths']['n_final'] = 4 # Reidentification parameters par['calibrations']['wavelengths']['method'] = 'reidentify' par['calibrations']['wavelengths'][ 'reid_arxiv'] = 'vlt_xshooter_nir.fits' par['calibrations']['wavelengths']['cc_thresh'] = 0.50 par['calibrations']['wavelengths']['cc_local_thresh'] = 0.50 par['calibrations']['wavelengths']['ech_fix_format'] = True # Echelle parameters par['calibrations']['wavelengths']['echelle'] = True par['calibrations']['wavelengths']['ech_nspec_coeff'] = 5 par['calibrations']['wavelengths']['ech_norder_coeff'] = 5 par['calibrations']['wavelengths']['ech_sigrej'] = 3.0 # Flats par['calibrations']['flatfield']['illumflatten'] = False par['calibrations']['flatfield']['tweak_slits_thresh'] = 0.90 par['calibrations']['flatfield']['tweak_slits_maxfrac'] = 0.10 # Always correct for flexure, starting with default parameters par['flexure'] = pypeitpar.FlexurePar() # Is this needed below? par['scienceframe']['process']['sigclip'] = 20.0 par['scienceframe']['process']['satpix'] = 'nothing' # TODO tune up LA COSMICS parameters here for X-shooter as tellurics are being excessively masked # Extraction par['reduce']['skysub']['bspline_spacing'] = 0.8 par['reduce']['skysub'][ 'global_sky_std'] = False # Do not perform global sky subtraction for standard stars par['reduce']['extraction'][ 'model_full_slit'] = True # local sky subtraction operates on entire slit par['reduce']['findobj']['trace_npoly'] = 8 par['reduce']['findobj'][ 'find_npoly_cont'] = 0 # Continnum order for determining thresholds par['reduce']['findobj'][ 'find_cont_fit'] = False # Don't attempt to fit a continuum to the trace rectified image # The settings below enable X-shooter dark subtraction from the traceframe and pixelflatframe, but enforce # that this bias won't be subtracted from other images. It is a hack for now, because eventually we want to # perform this operation with the dark frame class, and we want to attach individual sets of darks to specific # images. par['calibrations']['biasframe']['useframe'] = 'bias' par['calibrations']['traceframe']['process']['bias'] = 'force' par['calibrations']['pixelflatframe']['process']['bias'] = 'force' par['calibrations']['arcframe']['process']['bias'] = 'skip' par['calibrations']['tiltframe']['process']['bias'] = 'skip' par['calibrations']['standardframe']['process']['bias'] = 'skip' par['scienceframe']['process']['bias'] = 'skip' # Sensitivity function parameters par['sensfunc']['algorithm'] = 'IR' par['sensfunc']['polyorder'] = 8 par['sensfunc']['IR']['telgridfile'] = resource_filename( 'pypeit', '/data/telluric/TelFit_Paranal_NIR_9800_25000_R25000.fits') return par
def test_flexure(): pypeitpar.FlexurePar()
# Read the baseline file that is not changed and must be edited by # the person building the documentation as necessary. pypeit_root = os.path.dirname(resource_filename('pypeit', '')) input_base = os.path.join(pypeit_root, 'doc', 'scripts', 'base_par_rst.txt') with open(input_base, 'r') as f: lines = [l.replace('\n', '') for l in f.readlines()] lines += [''] # Start to append the automatically generated documentation lines += ['Current PypeItPar Parameter Hierarchy'] lines += ['+++++++++++++++++++++++++++++++++++++'] lines += [''] p = pypeitpar.PypeItPar(flexure=pypeitpar.FlexurePar(), fluxcalib=pypeitpar.FluxCalibratePar()) lines += par_hierarchy(p) lines += [''] lines += ['----'] lines += [''] lines += p.to_rst_table() lines += [''] lines += [' .. _instr_par:'] lines += [''] lines += ['Instrument-Specific Default Configuration'] lines += ['+++++++++++++++++++++++++++++++++++++++++']