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.37.tar.gz
(175.3 kB
view hashes)
Built Distributions
Close
Hashes for ncephes-1.0.37-cp36-cp36m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4ccf65a93eebdf938cd15c56063f37cefdb051d4ac2b4635f1634049baacb906 |
|
MD5 | 8d24d95fd0e2e5b4a42427d2452c57ab |
|
BLAKE2b-256 | 7f840aa2554bb05f1809da440998612447e798a358c147a33fac4d33a54bcb1f |
Close
Hashes for ncephes-1.0.37-cp36-cp36m-macosx_10_11_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a341f4943413e34794f3b365e47aafbf13dd915b77f449a0f0d7a5b63e2a76c7 |
|
MD5 | c4b22d6fceb870c7da20b72945a228cb |
|
BLAKE2b-256 | c5d1693da9709605f8717683d28d23ca1b84a139fb46940c0499d6473239c5fd |
Close
Hashes for ncephes-1.0.37-cp35-cp35m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f92de82443b9dadde7fae391bec9ec59bdd47ee3a30877c2c287708af0c76a97 |
|
MD5 | 1e6acd298cad44a6ad3f4f928c86dd59 |
|
BLAKE2b-256 | 8ed940ede49f611199d3b04a740e4a8a34047a1eff46058c303165860b58f0c6 |
Close
Hashes for ncephes-1.0.37-cp35-cp35m-macosx_10_11_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 518cc97daef71dbcad1434f2adfe8a22871adbc198c166139435f806658009c3 |
|
MD5 | 6f4c36ce296be9cf8dac66ca37cd36a5 |
|
BLAKE2b-256 | 7fa4394706cadaf6e5df6c194833bd35599226b673050fc0fd39040f722205af |
Close
Hashes for ncephes-1.0.37-cp27-cp27mu-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ad750b266faf25e970576686dcdcea0daf767b4627c7e9e0bdab2b635bce6845 |
|
MD5 | 53429e516265e19012cd2cf1d95a8a92 |
|
BLAKE2b-256 | cab8b0022fad601d31e7468573b7d67cf2ada82363eefbc0807faedd33434102 |
Close
Hashes for ncephes-1.0.37-cp27-cp27m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9e686063af69da310eb0e41cfabffccb7d4dcfbb4d8dd271cef525c84aca38b3 |
|
MD5 | 058ab92600467dc8d00bbc8d5dae3d43 |
|
BLAKE2b-256 | 105b46616abec3f1bc78602f28c5713f8ee98e86ed7a9d5491a2a1460382ed64 |
Close
Hashes for ncephes-1.0.37-cp27-cp27m-macosx_10_11_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 25ae99ca5d9a110e92d0662362213c4e0d95d5096a6f28f6a3ead0ef52dceb46 |
|
MD5 | a41323f5c91ff89f88cc536e3a86c377 |
|
BLAKE2b-256 | 19f8c1be9a86468b3ae5a3933cdf1d21a97182e92ab536ddbd6dedc96c6f2c9d |