smooth_images_toresolution

higal_sedfitter.smooth.smooth_images_toresolution(target_resolution, globs=['destripe*P[LMS]W*fits', 'destripe*blue*fits', 'destripe*red*fits'], reject_regex='smooth|smregrid', verbose=True, skip_existing=True, regrid=True, target_header=None, regrid_order=1, clobber=False, **kwargs)[source]

Smooth a series of images to the same resolution. The output files will be of the form {inputfilename}_smooth.fits and {inputfilename}_smregrid.fits

Parameters:

target_resolution : Quantity

A degree-equivalent value that specifies the beam size in the output image

globs : list

A list of strings to pass into glob. All files found will be smoothed and possibly regridded.

reject_regex : str

A regular expression to apply to each discovered file to choose whether to reject it. For example, if you’ve run this function once, you’ll have files named file.fits and file_smooth.fits that you don’t want to re-smooth and re-regrid.

verbose : bool

Print messages at each step?

skip_existing : bool

If the output smooth file is found and this is True, skip and move on to the next

regrid : bool

Regrid the file? If True, target_header is also required

regrid_order : int

The order of the regridding operation. Regridding is performed with interpolation, so 0’th order means nearest-neighbor and 1st order means bilinear. Regridding is done with FITS_tools.hcongrid.hcongrid

clobber : bool

Overwrite files if they exist?

kwargs : dict

Returns:

Nothing. All output is to disk

Raises:

ValueError

If target_header is not specified but regrid is