Giter Club home page Giter Club logo

ganmapper's Introduction

Logo

GANmapper - Geospatial Content Generator

This is the official repo of GANmapper, a building footprint generator using Generative Adversarial Networks

Running GANmapper

1. Install prerequisites

Use environment.yml to create a conda environment for GANmapper

conda env create -f environment.yml
conda activate GANmapper

2. Prediction

Predictions can be carried out by running the following sample code. The name of the city depends on the name of each dataset.

python predict.py --dataroot <path to XYZ tile dir> --checkpoints_dir <path to checkpoint> --name <cityname> 

Testing an area in LA:

python predict.py --dataroot datasets/Exp4/LA/Source --checkpoints_dir checkpoints/Exp3 --name LA 

Testing an area in Singapore:

python predict.py --dataroot datasets/Exp4/Singapore/Source --checkpoints_dir checkpoints/Exp3 --name Singapore 

The result will be produced in XYZ directories in ./results/<cityname>/test_latest/images/fake

You can choose to visualise the tiles in QGIS using a local WMTS server.

For example, use the following url and choose Zomm 16 only.

file:///D:/GANmapper//results/Singapore/test_latest/images/fake/{z}/{x}/{y}.png

Vectorization

If you want the output to be in Geojson polygons, use extract.py

  python extract.py <tile_dir>  <out> 
  python extract.py results/Exp4/LA/test_latest/images/fake LA.geojson

License

Distributed under the MIT License. See LICENSE for more information.

Acknowledgements

GANmapper is made possible by using the following packages

ganmapper's People

Contributors

iceofsky avatar

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.