# convert_pixel_to_data¶

sunpy.wcs.convert_pixel_to_data(size, scale, reference_pixel, reference_coordinate, x=None, y=None)[source] [edit on github]

Deprecated since version 0.8.0: The convert_pixel_to_data function is deprecated and may be removed in a future version. Use sunpy.map.GenericMap.pixel_to_world instead.

Calculate the data coordinate for particular pixel indices.

Parameters: size (2d ndarray) – Number of pixels in width and height. scale (2d ndarray) – The size of a pixel (dx,dy) in data coordinates (equivalent to WCS/CDELT) reference_pixel (2d ndarray) – The reference pixel (x,y) at which the reference coordinate is given (equivalent to WCS/CRPIX) reference_coordinate (2d ndarray) – The data coordinate (x, y) as measured at the reference pixel (equivalent to WCS/CRVAL) x,y (int or ndarray) – The pixel values at which data coordinates are requested. If none are given, returns coordinates for every pixel. out (ndarray) – The data coordinates at pixel (x,y).

Notes

This function assumes a gnomic projection which is correct for a detector at the focus of an optic observing the Sun.