TerraTracer
Geospatial tool for converting land certificates to precision GIS polygon maps using bearing + distance sequences
TerraTracer
TerraTracer converts land certificates (BLM mining claims, property deeds, survey descriptions) into precision GIS polygon maps. It takes bearing + distance sequences from legal descriptions and outputs KML (Google Earth) and GeoJSON (GIS tools) files.
Repositories
| Location | Type | URL |
|---|---|---|
| GitHub | Primary | YourGitHubUsername/TerraTracer |
| Gitea | Mirror | git.argobox.com/InovinLabs/TerraTracer |
| ArgoBox | Web App | /playground/terratracer |
Architecture
Python CLI (primary)
Core engine: core_geodesic.py — uses geographiclib (Karney/WGS84 ellipsoidal model) for sub-inch accuracy at any distance.
Input: Tie point (lat/lng) + sequence of bearing/distance segments from land certificate descriptions.
Output:
- KML file (Google Earth visualization)
- GeoJSON file (GIS tool import)
- Matplotlib plot (visual verification)
- CSV coordinates
Key libraries: GeoPandas, GDAL, Matplotlib, geographiclib
Test coverage: 43 pytest tests — all passing. Core geodesic accuracy verified: 0.007ft closure on rectangle, 0.076ft on lode claim.
Web App (/playground/terratracer)
Browser-based port of core logic using haversine (spherical) approximation. Sufficient for typical claim sizes (<50km) with <0.1% error.
Layout:
┌────────────────┬──────────────────────────┐
│ Input Form │ Leaflet.js Map │
│ (left, 400px) │ (right, flex-grow) │
├────────────────┴──────────────────────────┤
│ Export Bar: KML | GeoJSON | Copy Coords │
└───────────────────────────────────────────┘
Features:
- Tie point input (decimal degrees or DMS)
- Add/remove bearing+distance segments
- Real-time polygon drawing on map as segments are added
- Clickable vertices with coordinate info
- Area and perimeter display
- KML and GeoJSON download
- Pre-populated demo: 4-segment rectangle near Washington DC
CDN dependencies: Leaflet.js 1.9.4 (map), CARTO dark tiles (basemap). No npm dependencies.
Use Cases
- Mining Claims — Convert BLM land certificates to plottable polygons
- Property Boundaries — Map deed descriptions for real estate
- Drone Flight Paths — Define survey boundaries from legal descriptions
- Survey Verification — Cross-check surveyor reports against legal descriptions
- Rockhounding — Map mineral rights boundaries
- Historical Research — Digitize old paper certificates
How It Works
- Input — Enter starting tie point coordinates + bearing/distance sequence from legal description
- Calculate — Geodesic forward calculation: each bearing+distance from current point produces next point
- Export — Download KML (Google Earth), GeoJSON (GIS), or copy coordinates
Known Issues
- Vincenty method broken: Missing
geopy_distanceimport incomputation.py— use Karney (default) instead - KML color format: Has
#prefix but should be plainaabbggrr(ABGR format) - Dead code: Unreachable code after
returninorder_points() - Tkinter dependency: GUI mode fails in headless environments
- Web app area calc: Shoelace formula on lat/lng gives square degrees, not meters — needs projection fix
Future: PDF OCR Pipeline
Planned feature to scan PDF land certificates → OCR → parse bearing/distance sequences → auto-populate TerraTracer segments → generate polygon. Not yet built.
Related
- ArgoBox Projects — Public project showcase
- Playground Control — Lab environment management