reproject_interp¶
-
reproject.reproject_interp(input_data, output_projection, shape_out=None, hdu_in=0, order='bilinear', output_array=None, return_footprint=True)[source]¶ Reproject data to a new projection using interpolation (this is typically the fastest way to reproject an image).
Parameters: - input_data : str or
HDUListorPrimaryHDUorImageHDUor tuple The input data to reproject. This can be:
- The name of a FITS file
- An
HDUListobject - An image HDU object such as a
PrimaryHDU,ImageHDU, orCompImageHDUinstance - A tuple where the first element is a
ndarrayand the second element is either aWCSor aHeaderobject
- output_projection :
WCSorHeader The output projection, which can be either a
WCSor aHeaderinstance.- shape_out : tuple, optional
If
output_projectionis aWCSinstance, the shape of the output data should be specified separately.- hdu_in : int or str, optional
If
input_datais a FITS file or anHDUListinstance, specifies the HDU to use.- order : int or str, optional
The order of the interpolation. This can be any of the following strings:
- ‘nearest-neighbor’
- ‘bilinear’
- ‘biquadratic’
- ‘bicubic’
or an integer. A value of
0indicates nearest neighbor interpolation.- output_array : None or
ndarray An array in which to store the reprojected data. This can be any numpy array including a memory map, which may be helpful when dealing with extremely large files.
- return_footprint : bool
Whether to return the footprint in addition to the output array.
Returns: - input_data : str or