Git Product home page Git Product logo

saharaosm's Introduction

SaharaOSM

A specialized OpenStreetMap Mapnik style for the Sahara and other desertic regions.

It is possible to have a look at the final result here:

http://tmpsahara.dyndns.org

(Temporary hosting on a Raspberry Pi).

Current Extent

The project is set up to cover mainly Morroco (up to Western Sahara region), and part of Mauritania. However, there are no difficulties to make it cover larger/different area. The relief directory contains a Makefile that should then be changed to take into account different elevation tile names.

Setup

There is currently no utility to adapt the various parameters of the project: database names are fixed, host is localhost, and the absolute path to relief files will have to be changed manually. I will provide script to do this automatically in the future.

Databases

You need OpenStreetMap data loaded into a PostGIS database called africa, imported with the import style africa.style located in the import directory.

I use the Africa extract from geofabrik.de:

Then you need to set up an empty PostGIS database called africa_contours that will receive contours vectors later on.

Shapefiles

Please don't use get_shapefiles.sh, which has not yet been adapted for this project. You will have to manually download the following files:

Put these zip files at path/to/SaharaOSM/data and extract them in their natural directories.

Elevation data

You will need SRTM v4 90m Digital Elevation Data from CGIAR:

The data are available by http here:

http://srtm.csi.cgiar.org/SRT-ZIP/SRTM_V41/SRTM_Data_GeoTiff/srtm_xx_yy.zip

where xx_yy is a tile number corresponding to latitude/longitude. You will find the required tile numbers in the Makefile of the relief directory.

Ensure gdal utilities are installed and available from the command line. Then, to generate necessary tif relief files type:

make all

If you have a multicore CPU, you can speed-up the process by adding -j number_of_cpu_you_have to make, which will launch the various commands in parallel.

After making sure you have set up en empty PostGIS database called africa_contours, you can type:

make import-contours

which will extract contours from the elevation data and will import them in the database. Warning, this process can take a long time...

Dependencies

  • TileMill - This is a TileMill project you can copy (or symlink) directly into your Mapbox/project directory

If you aren't using TileMill, you can compile the CartoCSS stylesheets into Mapnik XML using the command-line carto command.

  • carto >= 0.9.3 (we're using instances with cascading rules)
  • mapnik >= 2.1.0

saharaosm's People

Contributors

firefishy avatar gravitystorm avatar ian29 avatar jecor avatar tmcw avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

pierrelorioux

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.