Numerical Geomorphology Package
Project description
soillib
soillib is a library and toolbox for numerical geomorphology simulation on the GPU
Written in in C++23 + CUDA and exposed to Python3 through nanobind
Maintained by erosiv. Based on concepts developed by and maintained by Nicholas McDonald.
Tested on Windows and Linux.
Description
soillib is a unified C++23 library for numerical geomorphology simulation, with a Python3 layer built on top. The library is designed with a high degree of compatiblity with Python in mind.
soillib provides modularized and unified concepts for many aspects of geomorphological simulations, from high-performance indexing structures to unified particle physics and unified data import and export interfaces, including native GeoTIFF support.
soillib is fully statically typed in C++, while allowing for dynamic types in the python interface. It achieves this through a selector pattern, which generates statically typed code for all permitted types (constrained by concepts), while choosing these paths dynamically. This leads to deep inlining and full static performance benefits.
This allows for creating complex geomorphological simulations through elegant modular concepts in Python. All examples are implemented in Python, but are equally reproducible in C++.
soillib is interoperable with popular Python packages like numpy and pytorch, making it easy to integrate into new or existing projects quickly.
soillib is inspired by a number of predecessor systems and the difficulty of maintaining them all at the same time as concepts evolve. This allows for the maintenance of a single library, and re-implementing these programs on top of this library easily.
Features / Highlights
- GPU First Kernelized Erosion Models
- A Library of Kernelized Operations for Numerical Geomorphology
- Fully Statically Typed C++23 Library with Concepts
- Dynamically Typed Python Module
- Interoperability with Numpy / PyTorch
- Unified image import / export, including floating-point
.tiffdata and native GeoTIFF support.
Why C++23?
Concepts and type constraints are extremely convenient for defining complex operations which can be implemented for certain map and cell types, without becoming too specific.
Additionally, the introduction of "deducing this" in C++23 as well as the convenient std::format and std::print are features that reduce design complexity of the library.
Installation
Dependencies
- GLM
- LibTIFF
- CUDA Toolkit
- CMake
- Python3
- Scikit (pip)
Installing
Install through pypi.org using pip:
pip install soillib
Building
Build from source and install from this repository using pip:
git submodule update --init --recursive
pip install .
Re-building for development:
pip install --no-build-isolation -ve .
Build directly using CMake:
git submodule update --init --recursive
cmake -S . -B build
cmake --build build
Build Wheel Distributable:
pip wheel .
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 Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file soillib-1.1.2-cp312-abi3-win_amd64.whl.
File metadata
- Download URL: soillib-1.1.2-cp312-abi3-win_amd64.whl
- Upload date:
- Size: 30.5 MB
- Tags: CPython 3.12+, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
40e78bcd759e3656c333ae70de9856b0dcc28fef04b329bdf1111bba106e76e4
|
|
| MD5 |
7ccc977449052ca3b48a245116f50303
|
|
| BLAKE2b-256 |
81aa8d942d84fa2ad9a68149da7945ed92b30c1c00c066e740942b32463b2e31
|