SHTOOLS - Spherical Harmonic Tools
Project description
SHTOOLS/pyshtools is a Fortran-95/Python library that can be used to perform spherical harmonic transforms, multitaper spectral analyses, expansions of functions into Slepian bases, and standard operations on global gravitational and magnetic field data.
FEATURES
Supports all standard normalizations and phase conventions of the spherical harmonic functions.
Effortless conversion between real and complex harmonics, between phase conventions, and between 4π normalized, Schmidt semi-normalized, orthonormalized, and unnormalized harmonics.
Use of both regularly sampled geographic grids and grids appropriate for Gauss-Legendre quadrature.
Spherical harmonic transforms proven to be accurate up to about degree 2800.
Perform localized multitaper spectral analyses, or expand functions in terms of localized Slepian bases.
Support for standard data and file formats, including xarray and netcdf.
Import research-grade gravity, topography, and magnetic field datasets with a single command.
Creation of publication quality maps using Cartopy and pygmt.
OpenMP compatible and OpenMP thread-safe versions of the Fortran routines.
INSTALLATION
pyshtools (for Python)
Binary install using pip or conda:
pip install pyshtools
pip install --upgrade pyshtools # to upgrade a pre-existing installation
conda install -c conda-forge pyshtools # Linux and macOS only
conda update -c conda-forge pyshtools # to upgrade a pre-existing installation
Build from source:
pip install pyshtools --no-binary pyshtools
Install the develop branch from source:
pip install git+https://github.com/SHTOOLS/SHTOOLS@develop
For developers, install the requirements
# Linux
sudo apt-get install libblas-dev liblapack-dev g++ gfortran libfftw3-dev tcsh
# macOS: install fftw using brew or macports
brew install fftw
sudo port install fftw-3
# macOS: for LAPACK, link to the system '-framework Accelerate'
then clone the shtools repo and install manually:
git clone https://github.com/SHTOOLS/SHTOOLS.git
cd shtools
git checkout develop
pip install -e . # install into the shtools folder and link to the active python environment
SHTOOLS (for Fortran 95)
Clone the shtools repo, and then execute one (or both) of the following commands in the shtools directory:
make fortran
make fortran-mp # for OpenMP Fortran routines
Alternatively, use the brew package manager (macOS)
brew tap shtools/shtools
brew install shtools
brew install shtools --with-openmp # to install shtools with the OpenMP components.
or the macports package manager (macOS)
sudo port install shtools
Further installation instructions and options can be found in the web documentation.
HOW TO USE
SHTOOLS can be invoked in any Fortran 95 or Python program. The core software is written in Fortran 95, and Python wrappers and dedicated classes allow simple access to the fortran-compiled routines. A variety of Python tutorials and guides are included that demonstrate the major features of the library.
To get started, check out the following Python tutorials:
DEVELOPERS
We work on the develop branch and only push releases to master. Please base all pull requests on develop.
REFERENCE
Mark A. Wieczorek and Matthias Meschede (2018). SHTools — Tools for working with spherical harmonics, Geochemistry, Geophysics, Geosystems, 19, 2574-2592, doi:10.1029/2018GC007529.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file pyshtools-4.7.1.tar.gz
.
File metadata
- Download URL: pyshtools-4.7.1.tar.gz
- Upload date:
- Size: 69.1 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0.post20200917 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cb15fe572f45c4979f3e1dd3e413446c5e375f46f5b6cd7bc0abd76bae5cb551 |
|
MD5 | b5b1519bba6cea86f5b2951cc98f7ed1 |
|
BLAKE2b-256 | 7036afa8cf3a3272be0b8191106ae8aa37e88012ef635a0384a015e1e42765c2 |
File details
Details for the file pyshtools-4.7.1-cp38-cp38-win_amd64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp38-cp38-win_amd64.whl
- Upload date:
- Size: 6.7 MB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0fd764c22975975085098afe6e409fa337f8eed5b2685b2215c5794e8e773e6a |
|
MD5 | 691bf0f7d1892a9b86e0d9690807c047 |
|
BLAKE2b-256 | 662d65ce9f6d9a625bc1519723d74cb975e23e9200638b8628f7b3df6561ce25 |
File details
Details for the file pyshtools-4.7.1-cp38-cp38-manylinux1_x86_64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp38-cp38-manylinux1_x86_64.whl
- Upload date:
- Size: 10.8 MB
- Tags: CPython 3.8
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/2.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb51a1b30816dbe5ef099e06ee0a3de5fa02c406e5c5111bbc06f796d7a9e714 |
|
MD5 | d231acc23ca02547d075c7e6d4144e1c |
|
BLAKE2b-256 | da01efb046a31c7e7cf2cb260987b8b3cdf3d21f318c9c1f0c52d98f002ee898 |
File details
Details for the file pyshtools-4.7.1-cp38-cp38-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp38-cp38-macosx_10_9_x86_64.whl
- Upload date:
- Size: 3.0 MB
- Tags: CPython 3.8, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.8.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fdd88cadccbf574169ae53a30e7b507eb8295746880584415b554e7301c5e68f |
|
MD5 | f527da3cad4f6c214641812864a7fa0e |
|
BLAKE2b-256 | ad84a7f6604e8aeb42f7cf981a0c11edd9fc7a0dfc3f1dce8d8fbbaf7e9df8da |
File details
Details for the file pyshtools-4.7.1-cp37-cp37m-win_amd64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp37-cp37m-win_amd64.whl
- Upload date:
- Size: 6.7 MB
- Tags: CPython 3.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c154b1e7468445d4720736bb268f774bf38f17bad450e3e02c1228b148577c7b |
|
MD5 | d3b014bc3582910df3bf49c135de5652 |
|
BLAKE2b-256 | 9ee1f812fb9da0761a5c5440c017984d9ce2baf00ac286be72fbba7c2bd0128f |
File details
Details for the file pyshtools-4.7.1-cp37-cp37m-manylinux1_x86_64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp37-cp37m-manylinux1_x86_64.whl
- Upload date:
- Size: 10.8 MB
- Tags: CPython 3.7m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/2.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | db8b9c0485fd20bda2c047dd82545f80028913b14cc44960521c9d57983ee9ca |
|
MD5 | 124448acfd5594e58fc18b5902934020 |
|
BLAKE2b-256 | a44faf3be790d0cce0594d30897b4045e3f7c03149e25fb101d3d6a4bb9a2d81 |
File details
Details for the file pyshtools-4.7.1-cp37-cp37m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp37-cp37m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 3.0 MB
- Tags: CPython 3.7m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.7.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9aff9106bdba1fb37b70aa38003595ec16ebdd3b6ebbd5b50d4d3d4f52ff48f5 |
|
MD5 | d9e7551576c0493f095fbb26af58b408 |
|
BLAKE2b-256 | 6569f9a35415545849333eeb76af358edb814c409260c26b1f35f9f86a85ef5d |
File details
Details for the file pyshtools-4.7.1-cp36-cp36m-win_amd64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp36-cp36m-win_amd64.whl
- Upload date:
- Size: 6.7 MB
- Tags: CPython 3.6m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.6.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 294506ea6c8c6bf1e5fec8888ade6666d832eeefb8e2060a830e7ae08327ac1d |
|
MD5 | d9032518f1d84670986f02dfea485091 |
|
BLAKE2b-256 | e1742a2965e3c69bca9be1f0e875af116ba6140f59b3c6bcd2790c99b7c220f9 |
File details
Details for the file pyshtools-4.7.1-cp36-cp36m-manylinux1_x86_64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp36-cp36m-manylinux1_x86_64.whl
- Upload date:
- Size: 10.8 MB
- Tags: CPython 3.6m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.15.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/2.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6cc1a85ddba04980ef2d9bc4b47c89ce50084c8c7d6c87b0fa3dc53ecb71fe2a |
|
MD5 | a3419ff0a1eb45ef977b340b3f1b0623 |
|
BLAKE2b-256 | 4776a17e007a0e7f5f51eb824e4cfb5fc04fc6af5dd7181ed4caa53830e0886d |
File details
Details for the file pyshtools-4.7.1-cp36-cp36m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: pyshtools-4.7.1-cp36-cp36m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 3.0 MB
- Tags: CPython 3.6m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.49.0 CPython/3.6.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f2ee50de7ef45eb96268e87cc34103f1af015434189e58b8725a6b453ea4c416 |
|
MD5 | 2ea227769551be5f137e0d8e1917154c |
|
BLAKE2b-256 | d53e9260db628b66484e94781273d32d8764ea8bc8147bf64e83782f26eee4fd |