コード例 #1
0
ファイル: pixelfunc.py プロジェクト: dhanson/healpy
def nest2ring(nside, ipix):
    """Convert pixel number from NESTED ordering to RING ordering.

    Parameters
    ----------
    nside : int, scalar or array-like
      the healpix nside parameter
    ipix : int, scalar or array-like
      the pixel number in NESTED scheme

    Returns
    -------
    ipix : int, scalar or array-like
      the pixel number in RING scheme

    See Also
    --------
    ring2nest, reorder
    
    Examples
    --------
    >>> import healpy as hpy
    >>> hpy.nest2ring(16, 1130)
    1504

    >>> hpy.nest2ring(2, range(10))
    array([13,  5,  4,  0, 15,  7,  6,  1, 17,  9])
    
    >>> hpy.nest2ring([1, 2, 4, 8], 11)
    array([ 11,   2,  12, 211])
    """
    return pixlib._nest2ring(nside, ipix)
コード例 #2
0
ファイル: pixelfunc.py プロジェクト: jrs65/healpy
def nest2ring(nside, ipix):
    """Convert pixel number from NESTED ordering to RING ordering.

    Parameters
    ----------
    nside : int, scalar or array-like
      the healpix nside parameter
    ipix : int, scalar or array-like
      the pixel number in NESTED scheme

    Returns
    -------
    ipix : int, scalar or array-like
      the pixel number in RING scheme

    See Also
    --------
    ring2nest, reorder
    
    Examples
    --------
    >>> import healpy as hp
    >>> hp.nest2ring(16, 1130)
    1504

    >>> hp.nest2ring(2, range(10))
    array([13,  5,  4,  0, 15,  7,  6,  1, 17,  9])
    
    >>> hp.nest2ring([1, 2, 4, 8], 11)
    array([ 11,   2,  12, 211])
    """
    check_nside(nside)
    return pixlib._nest2ring(nside, ipix)
コード例 #3
0
ファイル: pixelfunc.py プロジェクト: Alwnikrotikz/healpy
def nest2ring(nside, ipix):
    """Convert pixel number from nest scheme number to ring scheme number.

    Input:
      - nside: the nside to work with
      - ipix: the pixel number (can be an array) in nest scheme
    Return:
      - a pixel number or an array of pixel numbers in ring scheme
    """
    return pixlib._nest2ring(nside, ipix)
コード例 #4
0
def nest2ring(nside, ipix):
    """Convert pixel number from nest scheme number to ring scheme number.

    Input:
      - nside: the nside to work with
      - ipix: the pixel number (can be an array) in nest scheme
    Return:
      - a pixel number or an array of pixel numbers in ring scheme
    """
    return pixlib._nest2ring(nside, ipix)