GSTools Cython backend
raw JSON → 1.2.0 verified Fri May 01 auth: no python
Provides the Cython-accelerated backend for GSTools, the geostatistical toolbox. Version 1.2.0 is the latest stable release. This package is not intended to be installed standalone; it is automatically included as a dependency of gstools. Release cadence is low, with major versions aligned to GSTools releases.
pip install gstools Common errors
error ModuleNotFoundError: No module named 'gstools_cython' ↓
cause Trying to import the Cython backend directly using underscore.
fix
Import gstools instead: import gstools
error Error: gstools-cython is not a Python package ↓
cause Trying to import with import gstools-cython (invalid syntax).
fix
Do not import this package. Install gstools and use import gstools.
Warnings
gotcha Do not install gstools-cython standalone. It is meant to be installed as a dependency of gstools. Standalone installation may cause version conflicts. ↓
fix Install gstools: pip install gstools
gotcha Importing gstools_cython directly (with underscore) fails because the package name uses a hyphen and the module name inside is not exposed. ↓
fix Do not import gstools-cython directly; import gstools instead.
breaking Requires Python >=3.10. Older Python versions are not supported. ↓
fix Upgrade Python to 3.10 or later.
Install
pip install gstools-cython Imports
- gstools-cython wrong
import gstools_cythoncorrectimport gstools-cython
Quickstart
import gstools as gs
# example usage of GSTools which automatically uses gstools-cython backend
model = gs.Gaussian(dim=2, var=1.0, len_scale=10.0)
srf = gs.SRF(model, seed=20170519)
field = srf((100, 100))
print(field.shape)