Pygimli logo

Pygimli

Community
SteadfastAsArt
pygimli

Multi-method geophysical modelling and inversion framework. Use when the agent needs to: (1) Perform electrical resistivity tomography (ERT) inversion, (2) Run seismic refraction tomography (SRT), (3) Model induced polarization (IP) data, (4) Simulate ground penetrating radar (GPR), (5) Create finite element meshes for geophysical problems, (6) Perform joint inversions of multiple datasets, (7) Forward model geophysical responses, (8) Analyze time-lapse monitoring data.

Overview

PublisherSteadfastAsArt
Repositorygeoscience-skills
Skill namepygimli
Stars
75
Forks
9
Bundled files
3
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 3 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by SteadfastAsArt on GitHub. Read the source before you install it.

Installation

Install the Pygimli AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/SteadfastAsArt/geoscience-skills/tree/main/pygimli
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/SteadfastAsArt/geoscience-skills.git /tmp/geoscience-skills
mkdir -p .claude/skills
cp -r /tmp/geoscience-skills/pygimli .claude/skills/pygimli
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Pygimli in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Pygimli on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Pygimli is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

pyGIMLi - Geophysical Inversion

Quick Reference

python
import pygimli as pg
from pygimli.physics import ert, srt

# Load ERT data
data = ert.load("survey.ohm")

# Invert
mgr = ert.ERTManager(data)
model = mgr.invert(lam=20, verbose=True)

# View result
mgr.showResult()

Key Classes

ClassPurpose
pg.MeshFinite element meshes
pg.DataContainerSurvey data and geometry
pg.InversionBase inversion framework
ert.ERTManagerERT processing and inversion
srt.SRTManagerSeismic refraction inversion

Essential Operations

Load and View ERT Data

python
import pygimli as pg
from pygimli.physics import ert

data = ert.load("survey.ohm")
print(f"Measurements: {data.size()}")
ert.showData(data)  # Pseudosection

ERT Inversion

python
from pygimli.physics import ert

mgr = ert.ERTManager(data)
model = mgr.invert(
    lam=20,          # Regularization
    verbose=True
)
mgr.showResult()
resistivity = mgr.model

Seismic Refraction

python
from pygimli.physics import srt

data = srt.load("traveltimes.sgt")
mgr = srt.SRTManager(data)
model = mgr.invert(lam=30, zWeight=0.3)
mgr.showResult()

Create Custom Mesh

python
import pygimli as pg
from pygimli.physics import ert

data = ert.load("survey.ohm")
mesh = pg.meshtools.createParaMesh(
    data.sensors(),
    quality=34.0,
    paraMaxCellSize=5,
    boundary=2
)
pg.show(mesh)

Save and Export

python
# Save mesh and model
mgr.mesh.save("result_mesh.bms")
pg.save(model, "resistivity_model.vector")

# Export to VTK for ParaView
mgr.mesh.exportVTK("result", mgr.model)

Array Types

CodeArray
waWenner-alpha
wbWenner-beta
ddDipole-dipole
pdPole-dipole
ppPole-pole
slmSchlumberger
grGradient

Data Formats

FormatExtensionDescription
BERT/pyGIMLi.ohmUnified data format
Syscal.txtIRIS export
Res2DInv.dat2D inversion format
ABEM.ohmABEM Terrameter
SRT.sgtSeismic traveltimes

When to Use vs Alternatives

ScenarioRecommendation
Standard ERT inversion with common arrayspyGIMLi - simplest API, built-in array types
Seismic refraction tomography (SRT)pyGIMLi - integrated SRT manager
Multi-method inversion (DC, magnetics, gravity, EM)SimPEG - broader method coverage
Commercial ERT processing with reportingRes2DInv - industry standard, GUI-based
Custom forward operators or research flexibilitySimPEG - more modular design
FEM-based geophysical modellingpyGIMLi - native FEM mesh support

Choose pyGIMLi when: You need near-surface geophysical inversion (ERT, SRT, IP) with minimal code. Its manager classes (ERTManager, SRTManager) handle the full workflow from data loading to inversion to visualization in a few lines.

Avoid pyGIMLi when: You need methods beyond near-surface (use SimPEG), or you require a commercial-grade reporting pipeline.

Common Workflows

ERT data inversion and visualization

  • Load ERT data file with ert.load("survey.ohm")
  • Inspect data: check measurement count with data.size(), plot pseudosection
  • Remove outliers or bad data points
  • Create ERTManager with data
  • Run inversion: mgr.invert(lam=20) (start with higher lambda)
  • Check chi-squared value (target ~ 1)
  • Visualize result with mgr.showResult()
  • Export mesh and model to VTK for ParaView: mgr.mesh.exportVTK()
  • Adjust lambda and zWeight if needed, re-invert

Inversion Tips

  1. Start with higher lambda (50-100) and decrease
  2. Check data quality - remove outliers before inversion
  3. Use zWeight < 1 for layered structures
  4. Check coverage - low coverage = poorly resolved
  5. Chi-squared ~ 1 indicates good fit without overfitting

References

Scripts

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Pygimli AI skill do?

Multi-method geophysical modelling and inversion framework. Use when the agent needs to: (1) Perform electrical resistivity tomography (ERT) inversion, (2) Run seismic refraction tomography (SRT), (3) Model induced polarization (IP) data, (4) Simulate ground penetrating radar (GPR), (5) Create finite element meshes for geophysical problems, (6) Perform joint inversions of multiple datasets, (7) Forward model geophysical responses, (8) Analyze time-lapse monitoring data.

Why use Pygimli on TypingMind?

Because you install it once and use it with any model. Pygimli is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Pygimli in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/SteadfastAsArt/geoscience-skills/tree/main/pygimli. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Pygimli?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Pygimli?

As many as you like. As long as a model supports skills, you can use Pygimli with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Pygimli AI skill free?

Yes. It is published on GitHub by SteadfastAsArt under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇