Skip to main content

Healpix tools package for Python

Project description

https://badge.fury.io/py/healpy.svg https://anaconda.org/conda-forge/healpy/badges/version.svg https://github.com/healpy/healpy/actions/workflows/cibuildwheel.yml/badge.svg Documentation Status https://mybinder.org/badge_logo.svg https://zenodo.org/badge/DOI/10.5281/zenodo.2605425.svg http://joss.theoj.org/papers/10.21105/joss.01298/status.svg

Description

healpy is a Python package to handle pixelated data on the sphere. It is based on the Hierarchical Equal Area isoLatitude Pixelization (HEALPix) scheme and bundles the HEALPix C++ library.

HEALPix was developed to efficiently process Cosmic Microwave Background data from Cosmology experiments like BOOMERANG and WMAP but it is now used in other branches of Astrophysics to store data from all-sky surveys. The target audience used to be primarily the Cosmology scientific community but currently anyone interested in handling pixelated data on the sphere is very welcome to propose new features.

Capabilities

healpy provides utilities to:

  • convert between sky coordinates and pixel indices in HEALPix nested and ring schemes

  • find pixels within a disk, a polygon or a strip in the sky

  • apply coordinate transformations between Galactic, Ecliptic and Equatorial reference frames

  • apply custom rotations either to vectors or full maps

  • read and write HEALPix maps to disk in FITS format

  • upgrade and downgrade the resolution of existing HEALPix maps

  • visualize maps in Mollweide, Gnomonic and Cartographic projections

  • transform maps to Spherical Harmonics space and back using multi-threaded C++ routines

  • compute Auto and Cross Power Spectra from maps and create map realizations from spectra

The documentation can be found at https://healpy.readthedocs.io, tutorial at https://healpy.readthedocs.io/en/latest/tutorial.html, or execute it on mybinder

Requirements

  • Python 3.9, 3.10, or 3.11

  • Numpy (tested with version >=1.19)

  • Matplotlib

  • Python development package is required for some distribution (e.g., python-dev package for Ubuntu)

  • Astropy

Quick installation with Pip

The quickest way to install Healpy is with pip (>= 1.4.2), which automatically fetches the latest version of Healpy and any missing dependencies:

pip install --user healpy

If you have installed with pip, you can keep your installation up to date by upgrading from time to time:

pip install --user --upgrade healpy

See INSTALL.rst for further details and other installation options.

Optional

Healpy depends on the HEALPix C++ and cfitsio C libraries. Source code is include with Healpy and you do not have to install them separately.

However, if you have them installed already, Healpy should detect and reuse them instead of building them from source. To use your own installations of HEALPix and cfitsio, you will also need:

See INSTALL.rst for further instructions.

Known issues

  • Building with OpenMP support: the underlying HEALPix C++ library can be built to use OpenMP to speed up some operations on systems with multiple cores. Most, but not all, modern C/C++ compilers support OpenMP, the notable exception being clang.

    If your Healpy build fails with an error message about being unable to link against -lgomp, then this typically means that Healpy detected an already-installed HEALPix C++ library that was built with OpenMP support, but you are trying to build Healpy with a compiler that does not support OpenMP. Try cleaning the build with python setup.py clean –all, and set the environment variables CC and CXX to point to an OpenMP-capable compiler, such as gcc/g++.

  • Healpy does not currently support Windows. See https://github.com/healpy/healpy/issues/25.

  • Incompatibility with cfitisio from HEASOFT: due to a conflict of header file names it is currently not possible to use the cfitsio library provided with the HEASOFT package for compilation of HEALPix C++. HEASOFT’s include directory contains a file called “rotmatrix.h” which clashes with HEALPix’s own rotmatrix.h.

  • Compilation problems in the C++ package: some gcc versions (we have reports for 4.4.5 and 4.4.6) crash with an internal compiler error during compilation of libsharp. Unfortunately we have not found a workaround for this compiler problem. To our knowledge, it has been fixed in gcc 4.4.7 and in the 4.5.x and newer versions.

  • Healpy pixel functions, e.g. ang2pix, do not support 32-bit platforms. See https://github.com/healpy/healpy/issues/194.

Support

For specific HOWTO questions please create a question on StackOverflow and tag it with the healpy tag, so that answers will be easily searchable on google.

If you think you found a bug or you have install issues, open an issue on GitHub: https://github.com/healpy/healpy/issues

Contribute

Project development takes place on github, http://github.com/healpy/healpy, please open an issue over there for reporting bugs or suggest improvements. Collaboration is very welcome, just fork the project on github and send pull requests back to the main repository.

Developers

Core developers:

  • Cyrille Rosset

  • Andrea Zonca

  • Martin Reinecke

  • Leo Singer

  • Daniel Lenz

List of contributors: https://github.com/healpy/healpy/graphs/contributors

Acknowledgements

  1. Cite the HEALPix and healpy papers, see the CITATION file in the repository.

  2. Add an acknowledgment statement: “Some of the results in this paper have been derived using the healpy and HEALPix packages”.

  3. at the first use of the HEALPix acronym, a footnote placed in the main body of the paper referring to the HEALPix web site, currently http://healpix.sf.net

  4. You can also directly support the maintenance and development of healpy via Github Sponsors

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

healpy-1.17.1.tar.gz (4.4 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

healpy-1.17.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (8.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

healpy-1.17.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (8.3 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ ARM64

healpy-1.17.1-cp312-cp312-macosx_14_0_arm64.whl (2.7 MB view details)

Uploaded CPython 3.12macOS 14.0+ ARM64

healpy-1.17.1-cp312-cp312-macosx_11_0_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.12macOS 11.0+ x86-64

healpy-1.17.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (8.5 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

healpy-1.17.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (8.3 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ ARM64

healpy-1.17.1-cp311-cp311-macosx_14_0_arm64.whl (2.7 MB view details)

Uploaded CPython 3.11macOS 14.0+ ARM64

healpy-1.17.1-cp311-cp311-macosx_11_0_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.11macOS 11.0+ x86-64

healpy-1.17.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (8.3 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

healpy-1.17.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (8.2 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ ARM64

healpy-1.17.1-cp310-cp310-macosx_14_0_arm64.whl (2.7 MB view details)

Uploaded CPython 3.10macOS 14.0+ ARM64

healpy-1.17.1-cp310-cp310-macosx_11_0_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.10macOS 11.0+ x86-64

healpy-1.17.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (8.3 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

healpy-1.17.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (8.2 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ ARM64

healpy-1.17.1-cp39-cp39-macosx_14_0_arm64.whl (2.7 MB view details)

Uploaded CPython 3.9macOS 14.0+ ARM64

healpy-1.17.1-cp39-cp39-macosx_11_0_x86_64.whl (2.8 MB view details)

Uploaded CPython 3.9macOS 11.0+ x86-64

File details

Details for the file healpy-1.17.1.tar.gz.

File metadata

  • Download URL: healpy-1.17.1.tar.gz
  • Upload date:
  • Size: 4.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for healpy-1.17.1.tar.gz
Algorithm Hash digest
SHA256 6469fc9669e4cc6068c1509ba67228f215db57b3c2d6f00bd1eb481d97732e88
MD5 3f8a2e99f577f076b2e9996893908c70
BLAKE2b-256 c16dac7088628d2b86fb3ff4a3df93e213f2cf9cf25d13af0b2baa6337757271

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 2f5ea378e683f877f70870744abfbeb900d20e43ba024074763e3999d4db5402
MD5 5da0353a86ee3fa346f18b0472f3a47e
BLAKE2b-256 4a901827c294f3efdc93467bf23c4bbfc13d472f7525db86bb16dd489968deb7

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 378e36660d3df4ef5c85c1b0d782d5993c86daefafe0a1e4594e7f7a71792583
MD5 69f1a19a5d4f44990d4c3cdf44cf7eef
BLAKE2b-256 f058bde0b7bb89d5d409df8240cb117178ebbad9b1002d4bec89f18be09a1149

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp312-cp312-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp312-cp312-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 c66f35a77def27cfc444f1f9a36521c0a954a88eba7d11bec8c10616e0bb4a5b
MD5 e7079b299c426ddf4f57be99d14c2279
BLAKE2b-256 c6e9f8eff4c6c0d3532e72089aea661e2081fa801daaf0ec6c08a6f6df1a2db4

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp312-cp312-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp312-cp312-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 8a9db38eca26764b671156529edd6a19f9b5d5c9ed3f2bf190c8b1b93575a4ef
MD5 9db2810e5bbd821c09a3053d0b41adcc
BLAKE2b-256 2fa9f048b3a6e239e85019c768ecca632d0d021fbe7950d74998dfd6a7badfd2

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b05ba7ae36708371cce9b01934d86d22d17b0a81898b7b7c83e6f99b64933b62
MD5 283d7dcb6bb426c15cd3e5f16cf44398
BLAKE2b-256 25858d2fbf95d7a99db1c016eb61ea93071ad69c7dfed37480af20381b7c6d0d

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 80dee19bec6029df43ab606c4caefae945f787edc8a9e551a3189d437c0b52ba
MD5 0be60b6cb3be2bcbd879a99a62907cb5
BLAKE2b-256 1856ee941212e44719cd6400b61faf07d1f08b53a99251c98eb433cb9ff17d54

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp311-cp311-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp311-cp311-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 50b17c796fa90679d9618d6cbeb048ad4c82f226d97b0575f6f62c2ef7f8a788
MD5 e3b7b32832eb01d364f3d1451effeac7
BLAKE2b-256 beefb044c85dfb2578ae6d2ee2c521c2ed466997c4dd2d4b8f94e7ff1b57a5f6

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp311-cp311-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp311-cp311-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 63fbd4dbdac0d869aacb65d952ce0415c20393107fbe3ded18f682ba6b5e4a51
MD5 9e6f849d569d33cf1d9a20495f19cd18
BLAKE2b-256 c37519a52cbbdff9407f4aca060df8635c3feae26333468712beee5a3be7d4b0

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 610fe0255a5dd72108ad9778f0ca90422ebfa34ace098cace93b470186c9f6cc
MD5 671fee09d87efa1882ef3cc5d228d8d6
BLAKE2b-256 a98923849cd3d62ec3c522641d9b2d138f60fc982b83ae9e600a888bc9178ab2

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 574c714c17a23ae21668df4587b63f25d977436be685df51a1d11be217079ee9
MD5 5106aab58cad33e685ebb072a31cfa43
BLAKE2b-256 1c0a525ea1bf8ebb2358250cc1e0298d8bfa21be6bf063c5d9859f05b5ec0243

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp310-cp310-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp310-cp310-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 e06abb17b17e2ce586de37b0327dccd334d60802a4e20d7b67f349e248e6fd0f
MD5 72cc8c609ae3760aeaa2af19fc02520c
BLAKE2b-256 fba31d92592d1e3b9d78799342bf3dbb0e8fbb142238266e8e4809f68e7162be

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp310-cp310-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp310-cp310-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 19a5eea85f348896eb58e572ce25845cc0dc40661508b6b4b6e8fb4f34d50d74
MD5 73c18315eb933930703c70de7bfdd7f4
BLAKE2b-256 e40c384c1fd260176f9dfbf4ab364c0e2e7df08450811d186e00c3bbfa4fc5b4

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9f18548572b6a702e57071b70cc9818fe7ed74edaccbab5987ff55c6e9fd9b3a
MD5 184663e29b36a137996ed45a9ed37119
BLAKE2b-256 bd905ddd1609fd53050eedecd1c47d303fce2cef45f0b5c5ae17f34d3f7edd71

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 f521714cf325bc2886c95a7cd9e6a81d4e4583c6d478b0ffbe8d08d4da7d7954
MD5 19bde973a8d6274d907a7691866511a5
BLAKE2b-256 e3c683edc01f05f5b219c7f903858528f068d2495495848d22a09739ff0e7346

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp39-cp39-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp39-cp39-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 36e4699ed00aaec7dad9d22d8de635900e4a7b1bb4e6ce2dc9c0cb3ef47e6ec1
MD5 a4d40e61129a762c589d45b8c3e3a621
BLAKE2b-256 e7b334d858fade79a3ab72471415d93ca016f2893dc786305f3e0eecc50ea589

See more details on using hashes here.

File details

Details for the file healpy-1.17.1-cp39-cp39-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for healpy-1.17.1-cp39-cp39-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 26fc9a22939c04b09bdda3a9e72fb6969dd8e446b420ea7947b7e146d4c6c075
MD5 fa3bb7b63552a1e6205e9cff9866b312
BLAKE2b-256 9edff76a5b88a97d55e660b20131df595c1fb5861555fdcf5ef7a9aa17df5d13

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page