The sweep toolkit: seismic I/O, FWI losses, neural reparameterizations, the YAML
task runner and a natural-language agent, on top of the sweep wave-equation engine.
pip install sweepxThat installs the toolkit and the engine it runs on,
sweep-solver (import sweep), which ships
prebuilt CUDA cores. Optional extras: sweepx[segy], [hdf5], [animate],
[agent-ui], [mcp], [vllm], [all].
Installation guide.
| Module | What it does | Docs |
|---|---|---|
sweepx.io |
Seismic I/O — SEG-Y, acquisition geometry, data and model plans. | IO |
sweepx.loss |
Misfit functions for FWI — two dozen, from L2 to optimal transport. | Loss |
sweepx.nn |
Neural reparameterizations and priors — INR / hash / SIREN encoders, TV and diffusion priors. | NN |
sweepx.opt |
FWI optimizers — L-BFGS, truncated Newton / Gauss-Newton, Adam, Shampoo / SOAP, preconditioners and bound parameterizations. | Opt |
sweepx.tasks |
Production FWI / LSRTM / RTM runner — typed YAML task specs, a CLI, multi-GPU runs, field-data pipelines, preprocessing and plotting. | Tasks |
sweepx.agent |
Natural-language control layer — chat + files → validated runs, through a local LLM (Ollama / vLLM). | Agent |
The modules are layered: agent → tasks → io / loss / nn / opt. A module
imports only from the layers below it, and the four libraries neither import each other
nor the engine (checked in CI with import-linter).
sweep-tasks run examples/tasks/synthetic/09_forward_constant_box.yaml # or: sweepx tasks run …
sweep-tasks init fwi -o my_fwi.yaml # an annotated FWI template (any task type) ...
sweep-tasks run my_fwi.yaml # ... that runs as written: Marmousi, nothing to downloadimport sweep # the engine: equations, propagators
from sweepx.loss import EnvelopeLoss # the toolkit, one module at a time
from sweepx.tasks import load_task, TaskRunner…or in plain language, via the agent (needs a local LLM):
sweep-agent chat # or: sweepx agent chat
>>> load the Marmousi benchmark model and run a forward — show the shot gathergit clone https://github.com/DeepWave-KAUST/sweepx.git && cd sweepx
pip install -e ".[dev]"
pytest tests/loss # tests/<module>/ for each module
lint-imports # the layering contractMIT — see LICENSE.