CyRK - ODE Integrator Implemented in Cython and Numba
Contributors
Others:
Description
Runge-Kutta ODE Integrator Implemented in Cython and Numba
CyRK provides fast integration tools to solve systems of ODEs using an adaptive time stepping scheme. CyRK can, usually, accept differential equation functions that are written in pure Python, njited numba, or cython-based cdef classes. These kinds of functions are generally easier to implement than pure c functions. Using CyRK can speed up development time while not making a huge sacrifice when it comes to performance.
The purpose of this package is to provide some functionality of scipy's solve_ivp with greatly improved performance.
Currently, CyRK's numba-based (njit-safe) implementation is 10-120+x faster than scipy's solve_ivp function. The cython-based cyrk_ode
function that works with python (or numba) functions is 20-40+x faster than scipy. The cython-based CySolver
class that works with cython-based cdef methods is 30-500x faster than scipy.
An additional benefit of the two cython implementations is that they are pre-compiled. This avoids most of the start-up performance hit experienced by just-in-time compilers like numba.
To install simply run: `pip install CyRK` from a terminal where python 3.8-3.12 has been installed. The numpy, cython, and numba python packages are required. If you run into problems please check out the GitHub page for troubleshooting help or get in touch.
CyRK is open-source and we encourage you to learn more and contribute to its development. Find out how you can help here.
Files
CyRK-main.zip
Files
(1.6 MB)
Name | Size | Download all |
---|---|---|
md5:d9826e19ae8e0bdbab39071e4e6bb709
|
1.6 MB | Preview Download |
Additional details
Dates
- Updated
-
2024-02-13Updated for CyRK v0.8.6
Software
- Repository URL
- https://github.com/jrenaud90/CyRK
- Programming language
- Python, Cython, C
- Development Status
- Active