Python port of the MATLAB gridfit function (D'Errico, 2006).
To install the latest tagged version:
pip install pygridfitOr to install the development version, clone the repository and install it with pip install -e:
git clone https://github.com/berenslab/pygridfit.git
pip install -e pygridfitBy default, pygridfit uses scipy.sparse.linalg.spsolve to solve sparse matrices, which can be slow. For better performance, you can manually install the additional dependencies of scikit-sparse first:
# mac
brew install suite-sparse
# debian
sudo apt-get install libsuitesparse-devthen run:
pip install -e pygridfit[scikit-sparse]
See the example notebook for usage.