geophysical-inversion

geophysical-inversion is a skill for Claude Code, Codex from SteadfastAsArt/geoscience-skills. It costs 44 tokens per session (3,398 once invoked), scanned A, original, MIT.

A workflow for turning geophysical survey measurements into models of underground physical properties. It covers electrical resistivity, magnetics, gravity, and electromagnetic surveys.

In plain words
What is it for?
Loading survey data, creating meshes, running forward models and inversions, gridding results, validating trends, and producing 3D visualisations.
Why use it?
Raw survey measurements do not directly show the underground structures or properties that researchers need to interpret.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Loading survey data, creating meshes, running forward models and inversions, gridding results, validating trends, and producing 3D visualisations.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/steadfastasart/geoscience-skills/geophysical-inversion
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add SteadfastAsArt/geoscience-skills --skill geophysical-inversion
Clone the repo
git clone --depth 1 https://github.com/SteadfastAsArt/geoscience-skills

Made for: Claude Code, Codex.

Its marketplace also offers this one on its own, as the plugin geophysical-inversion — /plugin install geophysical-inversion after adding the marketplace above.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for geophysical-inversion

README.md
[![agentmods](https://agentmods.dev/badge/skills/steadfastasart/geoscience-skills/geophysical-inversion/github.svg)](https://agentmods.dev/skills/steadfastasart/geoscience-skills/geophysical-inversion)
Your own site
<a href="https://agentmods.dev/skills/steadfastasart/geoscience-skills/geophysical-inversion"><img src="https://agentmods.dev/badge/skills/steadfastasart/geoscience-skills/geophysical-inversion/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for geophysical-inversion

Your own site · 80×15
<a href="https://agentmods.dev/skills/steadfastasart/geoscience-skills/geophysical-inversion"><img src="https://agentmods.dev/badge/skills/steadfastasart/geoscience-skills/geophysical-inversion.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 44 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,398 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00044 $0.03398
Opus 5.5 $0.00018 $0.01359
Sonnet 5.5 $0.00009 $0.00680
Haiku 4.5 $0.00004 $0.00340

Measured 1mo ago against content hash 0754eb136f30, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

geophysical-inversion scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

workflows/geophysical-inversion/SKILL.md · 329 lines

How it starts

The opening of the file, as written. The whole thing — 329 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Geophysical Inversion Workflow

End-to-end pipeline for inverting geophysical data, from survey data loading through mesh creation, forward modelling, inversion, gridding, and 3D visualization of recovered physical property models.

Skill Chain

simpeg / pygimli      verde            pyvista
[Mesh + Inversion] --> [Gridding]    --> [3D Visualization]
  |                     |                |
  Survey geometry       Interpolate      Volume render
  Forward model         Grid to raster   Slice views
  Misfit + reg          Trend removal    Overlay data
  Recover model         Cross-validate   Export mesh

Decision Points: SimPEG vs pyGIMLi

Criterion SimPEG pyGIMLi
DC resistivity / ERT Yes Yes (simpler API)
Magnetics Yes Limited
Gravity Yes Limited
Electromagnetics (TDEM, FDEM) Yes No
Seismic refraction (SRT) No Yes
Induced polarization Yes Yes
Built-in electrode arrays Manual setup Built-in (Wenner, Schlumberger, etc.)
Mesh types TensorMesh, TreeMesh, CurvilinearMesh Triangular, tetrahedral, structured
Joint inversion Yes (Wires maps) Limited
API complexity More boilerplate, more flexible Less boilerplate, opinionated

Rule of thumb: Use pyGIMLi for standard near-surface ERT/SRT surveys with conventional arrays. Use SimPEG for multi-physics, EM methods, potential fields, or research-grade custom inversions.

Step-by-Step Orchestration

Choose one inversion branch. Each branch explicitly produces cell_centers_xz_m, resistivity_ohm_m and model_vtk for the shared stages. X is distance along the profile in metres, Z is elevation in metres (negative below the surface); resistivity is in ohm metres. These short synthetic runs check API and data flow, not survey resolution or field-model reliability.

Stage 1a: Inversion with SimPEG (DC Resistivity Example)

# example: simpeg-inversion
import numpy as np
from discretize import TensorMesh
from simpeg.electromagnetics.static import resistivity as dc
from simpeg import maps, data, data_misfit, regularization
from simpeg import optimization, inverse_problem, inversion, directives

# 1. Small synthetic 2D mesh. SimPEG's second coordinate represents elevation.
hx = np.full(24, 5.0)
hz = np.full(12, 5.0)
mesh = TensorMesh([hx, hz], origin='CN')

# 2. Build survey (dipole-dipole)
n_electrodes = 8
electrode_spacing = 5.0
elec_x = (np.arange(n_electrodes) - (n_electrodes - 1) / 2) * electrode_spacing
elec_locs = np.c_[elec_x, np.zeros(n_electrodes)]

source_list = []
for i in range(n_electrodes - 3):
    rx = dc.receivers.Dipole(elec_locs[[i+2]], elec_locs[[i+3]])
    src = dc.sources.Dipole([rx], elec_locs[i], elec_locs[i+1])
    source_list.append(src)
survey = dc.Survey(source_list)

# 3. Forward model (for synthetic test)
sigma_true = np.ones(mesh.nC) * 0.01  # 100 ohm-m background
sigma_true[mesh.cell_centers[:, 1] < -20] = 0.1  # Conductive layer
simulation = dc.Simulation2DNodal(
    mesh, survey=survey, sigmaMap=maps.ExpMap(mesh)
)
clean_data = simulation.dpred(np.log(sigma_true))
# Voltage / unit-current uncertainties: fractional term plus nonzero floor.
standard_deviation = 0.02 * np.abs(clean_data) + 1e-6
rng = np.random.default_rng(42)
dobs = clean_data + standard_deviation * rng.standard_normal(survey.nD)

# 4. Set up inversion
obs_data = data.Data(survey, dobs=dobs, standard_deviation=standard_deviation)
dmis = data_misfit.L2DataMisfit(data=obs_data, simulation=simulation)
reg = regularization.WeightedLeastSquares(
    mesh, alpha_s=1e-4, alpha_x=1, alpha_y=1
)
opt = optimization.InexactGaussNewton(maxIter=3)
inv_prob = inverse_problem.BaseInvProblem(dmis, reg, opt)
dir_list = [
    directives.BetaEstimate_ByEig(beta0_ratio=1.0, random_seed=42),
    directives.BetaSchedule(coolingFactor=2),
    directives.TargetMisfit()
]
inv = inversion.BaseInversion(inv_prob, directiveList=dir_list)

# 5. Run inversion
m0 = np.log(np.ones(mesh.nC) * 0.01)  # Starting model
mrec = inv.run(m0)
sigma_rec = np.exp(mrec)  # Recovered conductivity

Read the full file on GitHub · 329 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · +88 lines 0754eb136f30
  2. 2mo ago First seen · 241 lines · 44 tokens per session scan A ec4569abf13b

Subscribe to this mod's changes

geophysical-inversion is a skill published in the GitHub repository SteadfastAsArt/geoscience-skills (73 stars, last pushed 1mo ago), licensed MIT. It adds 44 tokens to every session and 3,398 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

earthquake-guide

Gates and workflows for the earthquake tools (USGS ComCat and EMSC). Use to judge how bad a quake was, read USGS aftershock odds, check whether a depth or location holds up, match one event across USGS and EMSC, or count and list events over years or in a region — before concluding from a missing product, a default…

cyanheads/earthquake-mcp-server · 88 tokens

glm-lake-mendota

Simulate vertical water temperature profiles for lakes using the General Lake Model (GLM), calibrate key parameters to minimize RMSE against field observations, and produce validated NetCDF output.

EtaYang10th/spark-skills · 0 tokens

xarray-netcdf

Labeled multi-dimensional array analysis with xarray: NetCDF/HDF5 I/O, lazy Dask loading, rechunking, Zarr stores, and CF conventions.

xjtulyc/awesome-rosetta-skills · 40 tokens

obspy-seismology

Seismological data analysis with ObsPy — FDSN waveform download, response removal, phase picking, moment tensor inversion, and seismicity mapping.

xjtulyc/awesome-rosetta-skills · 36 tokens

soil-data

Soil data analysis via SoilGrids 2.0 REST API and SSURGO: SOC stocks, texture classification, kriging interpolation, and soil profile visualization.

xjtulyc/awesome-rosetta-skills · 37 tokens

instrument-data-to-allotrope

Convert laboratory instrument output files (PDF, CSV, Excel, TXT) to Allotrope Simple Model (ASM) JSON format or flattened 2D CSV. Use this skill when scientists need to standardize instrument data for LIMS systems, data lakes, or downstream analysis. Supports auto-detection of instrument types. Outputs include full…

anthropics/knowledge-work-plugins · 123 tokens