Python interface for the Cephes library.
Project description
This package provides a python interface for the Cephes library. It also supports Numba and its nopython mode.
Usage
from ncephes import cprob
print(cprob.incbet(1., 3., 0.3))
prints 0.657.
You can also call them inside a numba function
from ncephes import cprob
from numba import jit
@jit
def numba_incbet(a, b, x):
return cprob.incbet(a, b, x)
print(numba_incbet(1., 3., 0.3))
and with nopython mode and nogil enabled
from ncephes import cprob
from numba import jit
incbet = cprob.incbet
@jit(nogil=True, nopython=True)
def numba_incbet(a, b, x):
return incbet(a, b, x)
print(numba_incbet(1., 3., 0.3))
One can also statically link the compiled Cephes libraries ncprob and ncellf. Please, have a peek at the examples/prj_name for a minimalistic example.
Install
The recommended way of installing it is via conda
conda install -c conda-forge ncephes
An alternative way would be via pip
pip install ncephes
Running the tests
After installation, you can test it
python -c "import ncephes; ncephes.test()"
as long as you have pytest.
License
This project is licensed under the MIT License - see the LICENSE file for details
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
ncephes-1.0.40.tar.gz
(181.8 kB
view hashes)
Built Distributions
Close
Hashes for ncephes-1.0.40-cp36-cp36m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9d781baecd4404991ee82c6006e5113580a568cbefbb520fa1d6a8c76a405b3d |
|
MD5 | 95b6cd49bcc0e434fa8d90ceea935b88 |
|
BLAKE2b-256 | aa286f7d8d80cee6cbf08ebe6acc3c3c8735304d10c174531aabd5db63013c20 |
Close
Hashes for ncephes-1.0.40-cp36-cp36m-macosx_10_11_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d4b48c3038b825e752693fb92611d44212408b01caf1abf6744e24f2d12f965 |
|
MD5 | 149abe3ae982695b7452694bb80893c2 |
|
BLAKE2b-256 | e1edd00fa3195a621af846030ac280be86d20014bf95e1649f9f59eba1196dd5 |
Close
Hashes for ncephes-1.0.40-cp35-cp35m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bb4ce18811803a96354407784a07e5d35b1bf5e76bf47b98d81f964a802334cd |
|
MD5 | 72e21cfe7f4e34ae9744db660d58bb7d |
|
BLAKE2b-256 | 23165db355e681c0d155adda933110dcc7e812ec9cfe3bece3138a46b0911a16 |
Close
Hashes for ncephes-1.0.40-cp35-cp35m-macosx_10_11_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 69f62e814c8ff70ae88dccafa6623ac605450e992a1edc7032460b531e7c07bd |
|
MD5 | 32c0463465e58162095732ff9df21fc5 |
|
BLAKE2b-256 | a47856a506e1e1bfc58d4c1a2255717881e2d112a702deaf45fed30a70f037dc |
Close
Hashes for ncephes-1.0.40-cp27-cp27mu-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 56ba57c94537331237224503800a72904489a302042405c7d986ae23437018e2 |
|
MD5 | 1e3391932475b0bbee8900756c73fb12 |
|
BLAKE2b-256 | ef6d3739de394c161dc6e2165ef8d23bbab82b876e176dd6df943c64bbec2b80 |
Close
Hashes for ncephes-1.0.40-cp27-cp27m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc84d135c156590cb24314fab9cb3a4ee77c9e55f39cdfead9c00ae1236e5a75 |
|
MD5 | 22d0f75724b9d832c262ad7cee565061 |
|
BLAKE2b-256 | 6474b0e88fb7c5cae09519c26f8a0074a38c543bf7dbcbf1e6038351964dcb3b |
Close
Hashes for ncephes-1.0.40-cp27-cp27m-macosx_10_11_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a29b7c34a21451817dba64b5c48271a3ab342278db54d71d7e8be139b4a23da3 |
|
MD5 | f8d09bef18e398224e4fa07c53e1d967 |
|
BLAKE2b-256 | 22077044aac23fbe9d02b611542794dcee50ead5c5c9e1168396c69e58c6a5ff |