Python interface for the Cephes library
Project description
Ncephes
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.
Authors
- Danilo Horta - https://github.com/Horta
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.1.0.tar.gz
(9.9 kB
view hashes)
Built Distributions
Close
Hashes for ncephes-1.1.0-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd462ac93003d9ab935b37944e47c67d8fe1861d00b0be4d3e151490b60101cd |
|
MD5 | 7f319b5a22e1829b15eaa918f195ab83 |
|
BLAKE2b-256 | 4fa45de7e785e7fcd3fe016306cad4f4a92dfe73e67192d94956cae697cc8743 |
Close
Hashes for ncephes-1.1.0-cp37-cp37m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a97146da7092d0f14e12937ddbfc41edd9268d62da5f5923afb313e92e71f8c9 |
|
MD5 | 5ae5082d18ac0bef84acf759c151af9d |
|
BLAKE2b-256 | 99da08b546fda0dd2038d5015a995546e112017d4760f02401105780ba1c36d1 |
Close
Hashes for ncephes-1.1.0-cp37-cp37m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 945f8d894924f629dbc93ef778088ef32d529c5aedc456fc1b5a8153883431d2 |
|
MD5 | 4fc9cfd2f7a0389b54ec33414b5ebcf8 |
|
BLAKE2b-256 | 3108f8e161167b5a3021d12043cc26f6f58fe8cd90ee89b353ff4986815cbc45 |
Close
Hashes for ncephes-1.1.0-cp36-cp36m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c145ec43fe62e5d9ca4132b67334dfb94443040e0658ff3d27edc7517a62e8d6 |
|
MD5 | 58d12f4138ffa31a1ca3d05222d0c88a |
|
BLAKE2b-256 | 78af830170d9dae1eb23cba93a814d58716b0e82b6bdc7ccb3a7d7592c9d3652 |
Close
Hashes for ncephes-1.1.0-cp36-cp36m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c630d3290bdb93bf7428cb26bfae6f01f78ff718ffbed08075f116221a225ff4 |
|
MD5 | dfee2a225ac471872ed7f13d995fc456 |
|
BLAKE2b-256 | d3fdbe2c17613a1d0ddbdc3a451471948ebf1c9dba80fedcbe7b2f909fdf3e26 |
Close
Hashes for ncephes-1.1.0-cp36-cp36m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0e65f7299c22088e8f36452f8ec9abf3160a66ea27f3168a35bb052e8f742ed1 |
|
MD5 | d78c01fa41936fb814f8d096d5022325 |
|
BLAKE2b-256 | 32296ce37e28e8742f1cad4b1b939772f16534031c19d965b9937fa2b754743f |
Close
Hashes for ncephes-1.1.0-cp27-cp27mu-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 532c96556bf1a9e0e1895ca59cafd97010cd763149d09116eeff32675f630683 |
|
MD5 | c2a0ca3f3f9b1ab0403d676445f6c60e |
|
BLAKE2b-256 | f5d3fd50368b44edf854755a4f9e5fbd7d35417ccb24f6167cdb0d09100e2201 |
Close
Hashes for ncephes-1.1.0-cp27-cp27m-manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cd6b0a3bdbe686f687248143eb818c67b6b93aa1d993dbcd93d36ee2ea1031b8 |
|
MD5 | f14c9e62cb53d7a3a57d191c49cec939 |
|
BLAKE2b-256 | 2acba6306771fc623c084189deba3ab30e552b604cd33fbb0a8d3317aac628f0 |
Close
Hashes for ncephes-1.1.0-cp27-cp27m-macosx_10_6_intel.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 77372da57df57623b26c7779cee096ab915888e61398f424a81d11148f0ce91e |
|
MD5 | 0b42e1f728747ba1b5fed1612404345e |
|
BLAKE2b-256 | 053ee94dab995dafe915cd6a53fbf90d5cfdb5d0950986a40677639db12db85d |