技能创建器
skill-creator
创建、改进和评估自定义技能,把专业流程转化为可重复使用的 AI 能力。
geopandas【数据与研究】Use when working with GeoPandas GeoDataFrame and GeoSeries workflows, vector geospatial I/O, CRS-aware spatial operations, mapping, geocoding, and GeoPandas-specific validation.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this skill when a task needs package-specific guidance for GeoPandas, the Python library that extends pandas with Shapely geometry columns, CRS-aware GeoSeries/GeoDataFrame objects, vector I/O, spatial analysis, mapping, geocoding, and geometry-aware testing.
GeoPandas requires Python 3.11+ for this snapshot. A base install should provide numpy, pandas, shapely, pyproj, pyogrio, and packaging.
import geopandas as gpd
from shapely.geometry import Point
gdf = gpd.GeoDataFrame({"name": ["a"], "geometry": [Point(0, 0)]}, crs="EPSG:4326")
assert gdf.crs.to_string() == "EPSG:4326"
For environment diagnostics from this skill directory:
python scripts/check_geopandas_environment.py --json
| Task signal | Read |
|---|---|
Constructing or repairing GeoDataFrame/GeoSeries, active geometry columns, CRS metadata, set_crs versus to_crs, missing/empty geometry, coordinate access, spatial-index basics | core-data-model |
Reading or writing files, GeoJSON, GPKG, WKB/WKT, Arrow, Parquet, Feather, GeoParquet/GeoArrow, PostGIS, pyogrio/Fiona, bbox/mask/columns/rows filters | io-formats |
| Spatial joins, nearest joins, overlays, clips, dissolves, predicates, buffers, distance/area, invalid geometry repair, spatial-index queries, vector analysis pipelines | spatial-operations |
Static .plot(), interactive .explore(), choropleths, folium/mapclassify/tile dependencies, geocoding, reverse geocoding, provider/network issues | mapping-geocoding |
geopandas.testing assertions, expected GeoDataFrame fixtures, equality tolerances, focused pytest selection, optional dependency test triage, repository-maintainer validation | validation-testing |
core-data-model to create/repair objects and validate CRS/geometry quality.io-formats to load inputs or persist outputs when file/database formats are involved.spatial-operations for analysis and geometry transformations.mapping-geocoding only when rendering maps or calling geocoding providers is part of the deliverable.validation-testing to assert results or maintain the repository.set_crs() only to assign known CRS metadata to existing coordinates; use to_crs() to transform coordinates.pyarrow, SQL/PostGIS, matplotlib, folium, mapclassify, geopy, and tile/basemap packages as optional workflow dependencies.The bundled references and scripts are sufficient for common GeoPandas operation without reopening the source checkout. Runtime scripts use tiny fixtures, temporary directories, or import checks and avoid network, credentials, destructive database writes, large notebooks, and benchmark-scale tasks by default.