Skip to content

codeforamerica/OpenTrails

Repository files navigation

Build Status

OpenTrails Converter and Validator

Description

These in-development tools will allow park agencies and other trail stewards to upload and transform their existing shapefile data describing trail systems--including trail segments, trailheads, and the areas they traverse--into OpenTrails-compliant GeoJSON and CSV files.

Current Status

The converter tool currently transforms shapefiles containing trail segment data (lines), producing:

  • trail_segments.geojson
  • named_trails.csv
  • stewards.csv

Future functionality will provide a similar transformation for shapefiles describing trailheads (points) and areas (polygons).

Install

OpenTrails is a Python Flask application that depends on Amazon S3 for storage of uploads.

  • Amazon Web Services configuration comes from the DATASTORE environmental variable, given in this form:

    s3n://<AWS key>:<AWS secret>@<S3 bucket name>

  • Set up a virtualenv

pip install virtualenv
virtualenv venv-opentrails
source venv-opentrails/bin/activate
  • Install the required libraries
$ pip install -r requirements.txt

Test

python tests.py

Run

OpenTrails uses a Procfile to get up and running. You can use a library like foreman or honcho to run the application locally.

foreman start

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

License and Copyright

Copyright 2014 Code for America, MIT License

About

OpenTrails (Open Trail System Specification) Converter & Validator

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published