healpy.pixelfunc.ud_grade

healpy.pixelfunc.ud_grade(map_in, nside_out, pess=False, order_in='RING', order_out=None, power=None, dtype=None)

Upgrade or degrade resolution of a map (or list of maps).

Parameters :

map_in : array-like or sequence of array-like

the input map(s) (if a sequence of maps, all must have same size)

nside_out : int

the desired nside of the output map(s)

pess : bool

if True, in degrading, reject pixels which contains a bad sub_pixel. Otherwise, estimate average with good pixels

order_in, order_out : str

pixel ordering of input and output (‘RING’ or ‘NESTED’)

power : float

if non-zero, multiply the result by (nside_in/nside_out)**power For example, power=-2 keep the sum of the map invariant

dtype : type

the type of the output map

Returns :

map_out : array-like or sequence of array-like

the upgraded or degraded map(s)

Examples

>>> import healpy as hp
>>> hp.ud_grade(np.arange(48.), 1)
array([  5.5 ,   7.25,   9.  ,  10.75,  21.75,  21.75,  23.75,  25.75,
        36.5 ,  38.25,  40.  ,  41.75])

Project Versions

Previous topic

healpy.pixelfunc.maptype

Next topic

healpy.pixelfunc.UNSEEN

This Page