Skip to content

This code facilitates the automatic update of mapbox tilesets using Microsoft SQL data to be implemented in a PowerBI dashboard.

License

Notifications You must be signed in to change notification settings

MeltonEngServ/MbPbi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

MbPbi: Library to update MapBox with MSSQL Data

Version 0.2.0

This is a code that facilitates the creation of Mapbox tilesets using Mapbox Tileset Service API.

Installation

Since this library relies in geopandas to handle the geopgraphic data from MSSQL it is important to follow the next steps to set up all the dependancies without problem.

1. Setting the environment * If not already create a folder of Virtual Environments using UI or powershell. PS C:\Users\username> mkdir VirtualEnvs * Using powershell or the Command Prompt navigate to that folder. PS C:\Users\username> cd "\path\to\VirtualEnvs" * Create Python virtual environment inside that folder. PS C:\Users\username\VirtualEnvs> python -m venv geo-env 2. Setting the envrionment

In order to use this Library you will need to download all the dependencies, most of them would be downloaded as part of this library. However shapely, fiona, pyproj and rtree might need to be installed manually using the windows wheels.

  1. Pandas
  2. Geopandas
  3. Pyproj
  4. Shapely, fiona, rtree
  5. pymssql
  6. geojson
  7. jsonschema

Contributors

Functionalities

The current version supports the following data sources:

  1. Microsoft SQL Server geometry databases.
  2. GeoJson data from a URL.
  3. Shapefiles from local directories.

This version also supports the data transformation function clip using 2 layers, where at least 1 must be polygon.

Since Mapbox does not allow complex geometries like MultiPolygon, MultiLinestring or Geometry Collection, this package will try to convert these geometries to simple ones and this might result in some topology loses.

Licence

About

This code facilitates the automatic update of mapbox tilesets using Microsoft SQL data to be implemented in a PowerBI dashboard.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published