Generated banner for Geomaster
Generated logo for Geomaster

Geomaster

K-DenseCommunityCreated by K-Dense Inc.

  • Skill
  • Tool integration
  • Science and research
  • MIT
  • Low risk
  • Has scripts

From the author

Supports geospatial research workflows for remote sensing, vector and raster GIS, spatial statistics, terrain and network analysis, and machine learning for Earth observation. Use when processing satellite imagery, aligning coordinate systems and raster grids, accessing STAC catalogs, analyzing geospatial time series, or implementing scientific GIS workflows in Python, R, Julia, JavaScript, C++, Java, Go, or Rust.
— the description by K-Dense Inc.

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

GeoMaster provides a structured approach to geospatial analysis, enabling researchers to handle complex workflows involving vector and raster data. It emphasizes rigorous data provenance, coordinate system verification, and alignment of spatial grids. The skill supports a wide range of tasks, including satellite imagery processing, terrain analysis, network routing, and machine learning for Earth observation, while providing best practices for data storage and cloud-based catalog access.

What it does

  • Provides standardized workflows for processing satellite imagery and raster data.
  • Facilitates coordinate system verification and transformation for spatial datasets.
  • Enables terrain analysis, including slope, aspect, and hillshade generation.
  • Supports vector analysis and spatial joins using GeoPandas.
  • Integrates with cloud-based STAC catalogs and Earth Engine for large-scale data discovery.
  • Offers recipes for efficient storage and handling of large geospatial datasets.

When to use it

  • When performing scientific GIS workflows in Python, R, Julia, or other supported languages.
  • When aligning disparate raster grids or coordinate systems for analysis.
  • When processing remote sensing data, such as calculating NDVI or performing image classification.
  • When conducting network analysis or spatial statistics on geographic data.
  • When accessing and processing data from cloud-based STAC catalogs.

Advantages

  • Promotes reproducible research through explicit provenance and metadata tracking.
  • Encourages rigorous handling of coordinate systems and data alignment.
  • Provides modular, reusable code recipes for common geospatial tasks.
  • Supports scalable workflows using Dask and cloud-native storage formats like COG.
  • Includes clear guidelines for handling nodata, masks, and radiometric transformations.

Usage examples

“Calculate the NDVI for a Sentinel-2 stack.”
The agent uses the raster helper to compute NDVI from a verified four-band stack, applying the correct scale and offset factors.
“Perform a spatial join between points and zones.”
The agent verifies that both datasets share a common CRS, performs the join, and calculates statistics like count and mean per zone.
“Search for Sentinel-2 imagery in a specific region.”
The agent uses the STAC client to query the Planetary Computer catalog for scenes within a bounding box and date range, filtering by cloud cover.
“Generate terrain metrics from a DEM.”
The agent processes a DEM to calculate slope, aspect, and hillshade, ensuring the input is a north-up projected grid with elevations in metres.

Install

  1. Download the skill as a ZIP:

    https://mp-staging.autogineer.com/agent-skills/k-dense-ai/geomaster/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip geomaster.zip -d .agents/skills

Documentation by K-Dense Inc.

GeoMaster

Geospatial analysis across vector/raster GIS, remote sensing, spatial ML, terrain, networks, and scientific applications. Start with the relevant workflow, inspect input provenance, and load only the reference needed for the task.

Tested scope and installation

The local recipe suite targets GeoPandas 1.2.0, Rasterio 1.5.2, Shapely 2.1.2, PyProj 3.8.0, Rioxarray 0.23.0, Xarray 2026.9.0, OSMnx 2.1.1 and PySTAC Client 0.9.0. See review and source ledger for execution limits. Examples requiring actual input files are templates; authenticated Earth Engine/CDS/commercial services, desktop GIS and GPU training remain illustrative.

# In a dedicated environment; install only the workflow's optional dependencies.
uv venv --python 3.13
uv pip install geopandas==1.2.0 rasterio==1.5.2 shapely==2.1.2 pyproj==3.8.0
uv pip install rioxarray==0.23.0 xarray==2026.9.0 'dask[array]' scikit-learn==1.9.1
uv pip install pystac-client==0.9.0 planetary-computer==1.0.0 odc-stac
# For osgeo/native CLI or PDAL, use a separate conda-forge environment:
# conda create -n geo-native -c conda-forge python=3.13 gdal pdal python-pdal

Install TorchGeo/PyTorch, RSGISLib, Py6S/6S, ArcPy, QGIS or other specialist runtimes separately when required. A Rasterio wheel includes its own GDAL library; it does not install osgeo or the GDAL command-line programs.

Workflow

  1. Record product/collection ID, acquisition time, processing baseline, license, band names, scale/offset, QA meaning, horizontal/vertical CRS and units.

  2. Verify CRS from authoritative metadata. set_crs labels coordinates; to_crs transforms them. Never infer an unknown CRS from plausible bounds.

  3. Align extent, affine transform, dimensions, pixel registration and resolution. Reproject categorical masks with nearest-neighbor resampling; choose an appropriate resampler for continuous data. Matching array shape alone does not prove alignment.

  4. Preserve nodata, clouds, shadows and saturation masks. Convert unsigned integers to floating point before differences; apply the provider's radiometric transform once.

  5. Run the analysis at a defensible support/resolution. Keep training labels and validation blocks separate. Terrain elevation and horizontal units must agree.

  6. Export CRS, transform, valid-data mask, units, model settings and provenance. Check numeric expectations on a small known fixture before scaling up.

Local raster recipes

Import the bundled raster helper from its directory (add that directory to PYTHONPATH or run from it). It implements small in-memory recipes; use windows/Dask for larger data. Writers require a new output path. It does not infer band identities or masks.

NDVI
from raster_workflows import write_ndvi

# This example assumes a VERIFIED four-band B02/B03/B04/B08 stack whose mask
# already excludes clouds/shadows, and harmonized DN reflectance = DN * 0.0001.
write_ndvi('s2_masked_stack.tif', 'ndvi.tif', red_band=3, nir_band=4,
           scale=0.0001, offset=0.0)

Do not use those indices or calibration for an arbitrary sentinel2.tif. SAFE products and STAC assets are often separate single-band rasters. Additive radiometric offsets affect even NDVI. EVI/SAVI require physical reflectance. normalized_difference keeps undefined ratios and invalid cells as NaN, not zero.

Terrain
import rasterio
from raster_workflows import terrain_metrics

with rasterio.open('dem_metres.tif') as src:
    slope_deg, aspect_deg, shade = terrain_metrics(
        src.read(1, masked=True), src.transform, src.crs)

The helper requires a north-up projected metric grid and elevations in metres. Aspect points downslope clockwise from north; it is undefined for flat cells. Slope is resolution-aware; nodata contaminating a derivative stencil stays invalid. Hillshade is an illumination visualization, not hydrological flow or exposure risk.

Classification
import geopandas as gpd
from raster_workflows import classify_imagery

training = gpd.read_file('training.gpkg')  # polygons with class_id in 1..65534
model = classify_imagery('masked_features.tif', training, 'classified.tif')

The helper checks CRS, geometry, labels, valid training pixels and overlapping labels, then preserves nodata in a uint16 output. It fits a small demonstration model; it does not measure accuracy. Use spatial/temporal holdouts at the field, scene or regional level before reporting predictive performance. See machine learning.

Vector analysis

import geopandas as gpd

zones = gpd.read_file('zones.geojson')
points = gpd.read_file('points.geojson')
if zones.crs is None or points.crs is None:
    raise ValueError('Resolve missing CRS before analysis')
points = points.to_crs(zones.crs)
joined = gpd.sjoin(points, zones, how='inner', predicate='within')
stats = joined.groupby('zone_id')['value'].agg(['count', 'mean', 'std'])

# Local data only: verify the estimated CRS area of use before accepting it.
metric = zones.to_crs(zones.estimate_utm_crs())
metric['area_m2'] = metric.area
buffers = metric.geometry.buffer(1000).to_crs(zones.crs)

within excludes boundary points; overlapping zones can duplicate observations. Choose and document a boundary/overlap policy. A projected CRS need not use metres or preserve area. UTM suits local regions, not every national, polar or global task.

Cloud catalogs and Earth Engine

Data sources documents current STAC, CDSE, CDS, Overpass and geocoding contracts. Discovery is separate from downloading pixels.

from pystac_client import Client
import planetary_computer

catalog = Client.open('https://planetarycomputer.microsoft.com/api/stac/v1',
                      modifier=planetary_computer.sign_inplace)
search = catalog.search(collections=['sentinel-2-l2a'],
                        bbox=[-122.5, 37.7, -122.3, 37.9],
                        datetime='2023-06-01/2023-06-30',
                        query={'eo:cloud_cover': {'lt': 20}}, max_items=5)
items = list(search.items())
if not items:
    raise ValueError('No matching scenes')
# Save item IDs/properties; inspect asset keys, scale/offset and QA before load.

limit controls page size; max_items bounds total traversal. Planetary Computer signing returns expiring SAS asset URLs; use unsigned IDs/metadata for durable provenance and sign near the time of access. Earth Engine requires prior ee.Authenticate() and ee.Initialize(project='your-registered-project'). Cloud filters at scene level do not replace per-pixel masks. The remote-sensing reference includes SCL masking and region summaries with an explicit exclusive date end.

Networks

import osmnx as ox
import networkx as nx
G = ox.graph_from_place('Portland, Maine, USA', network_type='drive')
G = ox.routing.add_edge_speeds(G)
G = ox.routing.add_edge_travel_times(G)
origin = ox.distance.nearest_nodes(G, -70.26, 43.66)
destination = ox.distance.nearest_nodes(G, -70.27, 43.67)
route = nx.shortest_path(G, origin, destination, weight='travel_time')

This makes public Nominatim/Overpass requests. Handle no-route results and inspect imputed speeds; these estimate free-flow time, not observed traffic. Use graph CRS for nearest-node coordinates and distinguish travel-time seconds from metres.

Efficient storage

import rioxarray
from rasterio.shutil import copy as rio_copy
from rio_cogeo.cogeo import cog_validate

cube = rioxarray.open_rasterio('large.tif', masked=True,
                             chunks={'band': 1, 'x': 1024, 'y': 1024})
# Compute bounded windows or reductions; do not force the entire cube into memory.
rio_copy('input.tif', 'output_cog.tif', driver='COG', compress='DEFLATE')
valid, errors, warnings = cog_validate('output_cog.tif')
if not valid:
    raise ValueError(errors)

Tiling/compression alone does not establish COG layout. Preserve or regenerate appropriate overviews at COG creation; do not mutate the result in place.

References

Citing Scientific Agent Skills

This skill is part of Scientific Agent Skills by K-Dense. If it materially contributed to a manuscript, report, presentation, or code release, add the paper to the references or software section and tell the user you did so:

Kassis, T., Agarwal, V., He, Y., Patel, D., & Brueckner, A. M. (2026). Scientific Agent Skills: A Library of Procedural Knowledge for Research Agents. arXiv:2609.00065. https://doi.org/10.48550/arXiv.2609.00065

Always cite the current version. The DOI and https://arxiv.org/abs/2609.00065 resolve to the latest arXiv version, so never append a version suffix such as v1. When network access is available, fetch https://arxiv.org/abs/2609.00065 (or http://export.arxiv.org/api/query?id_list=2609.00065) before writing the reference and take the author list, year, and version from that record. If the record lists a journal reference or publisher DOI, cite the published version instead.

Files

references/gis-software.md

GIS Software Integration

Native GIS integration, reviewed 2026-10-01. All examples are illustrative: these applications/licenses were not installed or executed. Run them in the GIS vendor's Python environment, check the installed version and inspect tool help before use. QGIS's latest cookbook currently redirects to 3.44, so use explicit 4.2 material when targeting its Qt6 runtime.

QGIS / PyQGIS

Running Python Scripts in QGIS
# Processing framework script
from qgis.core import (QgsProject, QgsVectorLayer, QgsRasterLayer,
                       QgsProcessingAlgorithm, QgsProcessingParameterRasterLayer)

# Load layers
vector_layer = QgsVectorLayer("path/to/shapefile.shp", "layer_name", "ogr")
raster_layer = QgsRasterLayer("path/to/raster.tif", "raster_name", "gdal")

# Add to project
QgsProject.instance().addMapLayer(vector_layer)
QgsProject.instance().addMapLayer(raster_layer)

# Access features
for feature in vector_layer.getFeatures():
    geom = feature.geometry()
    attrs = feature.attributes()
Processing algorithms

Run inside an initialized QGIS environment with Processing registered. Inspect the provider's current parameters before assembling a workflow:

import processing
processing.algorithmHelp('native:buffer')
result = processing.run('native:buffer', {
    'INPUT': metric_vector_layer, 'DISTANCE': 100, 'SEGMENTS': 8,
    'END_CAP_STYLE': 0, 'JOIN_STYLE': 0, 'MITER_LIMIT': 2,
    'DISSOLVE': False, 'OUTPUT': 'TEMPORARY_OUTPUT',
})
buffer_layer = result['OUTPUT']

For a custom QgsProcessingAlgorithm, implement parameter registration, processAlgorithm and createInstance, and return the actual produced destination. A placeholder destination variable is not an NDVI implementation. Raster calculations must use explicit bands, scale/offset, masks and a defined output grid as in the local raster helper; wire those through registered parameters rather than guessing Sentinel band positions. Validate QgsVectorLayer.isValid()/QgsRasterLayer.isValid() before adding or processing a layer.

Plugin Development
# __init__.py
def classFactory(iface):
    from .my_plugin import MyPlugin
    return MyPlugin(iface)

# my_plugin.py
from qgis.PyQt.QtCore import QSettings
from qgis.PyQt.QtGui import QAction  # QGIS 4 / Qt6
from qgis.core import QgsProject

class MyPlugin:
    def __init__(self, iface):
        self.iface = iface

    def initGui(self):
        self.action = QAction("My Plugin", self.iface.mainWindow())
        self.action.triggered.connect(self.run)
        self.iface.addPluginToMenu("My Plugin", self.action)

    def run(self):
        # Plugin logic here
        pass

    def unload(self):
        self.iface.removePluginMenu("My Plugin", self.action)

ArcGIS / ArcPy

Basic ArcPy Operations
import arcpy

# Set workspace
arcpy.env.workspace = "C:/data"

# Set output overwrite
arcpy.env.overwriteOutput = True

# Set scratch workspace
arcpy.env.scratchWorkspace = "C:/data/scratch"

# List features
feature_classes = arcpy.ListFeatureClasses()
rasters = arcpy.ListRasters()
Geoprocessing Workflows
import arcpy
from arcpy.sa import *

# Check out Spatial Analyst extension
arcpy.CheckOutExtension("Spatial")

# Set environment
arcpy.env.workspace = "C:/data"
arcpy.env.cellSize = 10
arcpy.env.extent = "study_area"

# Slope analysis
out_slope = Slope("dem.tif")
out_slope.save("slope.tif")

# Aspect
out_aspect = Aspect("dem.tif")
out_aspect.save("aspect.tif")

# Hillshade
out_hillshade = Hillshade("dem.tif", azimuth=315, altitude=45)
out_hillshade.save("hillshade.tif")

# Viewshed analysis
out_viewshed = Viewshed("dem.tif", "observer_points.shp")  # observer fields follow tool schema
out_viewshed.save("viewshed.tif")

# Cost distance
cost_raster = DistanceAccumulation("source.shp", in_cost_raster="cost.tif")
cost_raster.save("cost_distance.tif")

# Hydrology: Flow direction
flow_dir = FlowDirection("dem.tif")
flow_dir.save("flowdir.tif")

# Flow accumulation
flow_acc = FlowAccumulation(flow_dir)
flow_acc.save("flowacc.tif")

# Stream delineation
stream = Con(flow_acc > 1000, 1)
stream_raster = StreamOrder(stream, flow_dir)
Vector Analysis
# Buffer analysis
arcpy.Buffer_analysis("roads.shp", "roads_buffer.shp", "100 meters")

# Spatial join
arcpy.SpatialJoin_analysis("points.shp", "zones.shp", "points_joined.shp",
                           join_operation="JOIN_ONE_TO_ONE",
                           match_option="HAVE_THEIR_CENTER_IN")

# Dissolve
arcpy.Dissolve_management("parcels.shp", "parcels_dissolved.shp",
                          dissolve_field="OWNER_ID")

# Intersect
arcpy.Intersect_analysis(["layer1.shp", "layer2.shp"], "intersection.shp")

# Clip
arcpy.Clip_analysis("input.shp", "clip_boundary.shp", "output.shp")

# Select by location
arcpy.SelectLayerByLocation_management("points_layer", "HAVE_THEIR_CENTER_IN",
                                      "polygon_layer")

# Feature to raster
arcpy.FeatureToRaster_conversion("landuse.shp", "LU_CODE", "landuse.tif", 10)
ArcGIS Pro Notebooks
# ArcGIS Pro Jupyter Notebook
import arcpy
import pandas as pd
import matplotlib.pyplot as plt

# Use current project's map
aprx = arcpy.mp.ArcGISProject("CURRENT")
m = aprx.listMaps()[0]

# Get layer
layer = m.listLayers("Parcels")[0]

# Read the local ArcPy feature layer through a feature-class source path.
from arcgis.features import GeoAccessor, GeoSeriesAccessor
sdf = pd.DataFrame.spatial.from_featureclass(layer.dataSource)

# Plot
sdf.plot(column='VALUE', cmap='YlOrRd', legend=True)
plt.show()

# Geocode addresses
locator = "C:/data/locators/composite.locator"
results = arcpy.geocoding.GeocodeAddresses(
    "addresses.csv", locator, "Address Address",
    "geocoded_results.gdb/addresses"
)

GRASS GIS

Python API for GRASS
import grass.script as gscript
import grass.script.array as garray

# Run within an initialized GRASS mapset (for example launch through
# `grass /path/to/location/mapset --exec python workflow.py`). Merely writing
# GISDBASE/LOCATION_NAME/MAPSET with g.gisenv does not initialize a session.

# Import raster
gscript.run_command('r.in.gdal', input='elevation.tif', output='elevation')

# Import vector
gscript.run_command('v.in.ogr', input='roads.shp', output='roads')

# Get raster info
info = gscript.raster_info('elevation')
print(info)

# Match computational region/resolution to the imported DEM.
gscript.run_command('g.region', raster='elevation', align='elevation')
# Slope analysis
gscript.run_command('r.slope.aspect', elevation='elevation',
                    slope='slope', aspect='aspect')

# Buffer
gscript.run_command('v.buffer', input='roads', output='roads_buffer',
                    distance=100)

# Overlay
gscript.run_command('v.overlay', ainput='zones', binput='roads',
                    operator='and', output='zones_roads')

# Calculate statistics
stats = gscript.parse_command('r.univar', map='elevation', flags='g')

SAGA GIS

Using SAGA via command line

Tool IDs/parameters belong to a specific SAGA release. For the reviewed 9.12.1 slope/aspect/curvature tool, the library is ta_morphometry, ID 0:

import subprocess
subprocess.run(['saga_cmd', 'ta_morphometry', '0',
                '-ELEVATION', 'dem.sgrd', '-SLOPE', 'slope.sgrd',
                '-ASPECT', 'aspect.sgrd', '-UNIT_SLOPE', '1',
                '-UNIT_ASPECT', '1'], check=True)

Use saga_cmd ta_morphometry 0 -h and the matching version's tool documentation to confirm inputs/output units and method. For grid calculus/channel networks, discover the installed library/tool help instead of invented names such as GridCalculator or ChannelNetworkAndDrainageBasins. Parameter interfaces can differ across versions. Check exit status and output metadata; process success does not prove scientific validity.

Cross-Platform Workflows

Export QGIS to ArcGIS
import geopandas as gpd

# Read data processed in QGIS
gdf = gpd.read_file('qgis_output.geojson')

# Ensure CRS
gdf = gdf.to_crs('EPSG:32633')

# Export for ArcGIS as GeoPackage (not File Geodatabase)
gdf.to_file('arcgis_input.gpkg', driver='GPKG')
# ArcGIS can read GPKG directly

# Or export to shapefile
gdf.to_file('arcgis_input.shp')
Batch Processing
import geopandas as gpd
from pathlib import Path

# Process multiple files
input_dir = Path('input')
output_dir = Path('output')
output_dir.mkdir(parents=True, exist_ok=True)

for shp in input_dir.glob('*.shp'):
    gdf = gpd.read_file(shp)

    if gdf.crs is None:
        raise ValueError('Source CRS is unknown')
    gdf = gdf.to_crs(gdf.estimate_utm_crs())
    # Process in verified metre units
    gdf['area'] = gdf.geometry.area
    gdf.geometry = gdf.geometry.buffer(100)  # one active geometry for these formats

    # Export for various platforms
    basename = shp.stem
    gdf.to_file(output_dir / f'{basename}_qgis.geojson')
    gdf.to_file(output_dir / f'{basename}_arcgis.shp')

For more GIS-specific examples, see code-examples.md.

Sources: QGIS4.2, ArcGIS viewshed, distance accumulation, GRASS, SAGA9.12 tool0.

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Needs: Needs network access, Needs Python, Needs Node.js

The author says: Core examples require Python 3.12+ and GeoPandas, Rasterio, NumPy and PyProj. Optional workflows require their named packages, native GIS applications, GPU runtimes, or service credentials and network access.

Security

What our scanner noticed· Low risk

  • Instructions that use the network
  • Scripts that your agent may run

This skill includes scripts that your agent may run. Read them before you use it.

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Created by
K-Dense Inc.
Publisher
K-Dense (Community)
Source
K-Dense-AI/scientific-agent-skills · skills/geomaster · commit a25cf9e
Licence
MIT License (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE.md)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by K-Dense Inc. or K-Dense.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download geomaster.zip