Convert a vector tile to a png.
Project description
mvtToPng
A python package to convert a vector tile to a png.
Install
pip install mvtToPng
How to use
import os
from mvtToPng import converter
DIR_PATH = os.path.dirname(os.path.realpath(__file__))
FILE_PATH = os.path.join(DIR_PATH, "states_3_2_3.pbf")
DOWNLOAD_LOCATION = f"{os.getcwd()}/downloads"
with open(FILE_PATH, 'rb') as file:
vector_data = file.read()
converter.Converter(
vector_tile_in_bytes=vector_data,
z=3,
y=2,
x=3,
download_path=DOWNLOAD_LOCATION,
file_name="states"
).convert()
Example Image:
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mvttopng-1.0.1.tar.gz
(2.6 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mvttopng-1.0.1.tar.gz.
File metadata
- Download URL: mvttopng-1.0.1.tar.gz
- Upload date:
- Size: 2.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
52d90ee4414fc7086eac6fb06746e4347df0918f9223d3345a2d0e336efbd646
|
|
| MD5 |
3f02b59622030aefd38920cb2fe000ec
|
|
| BLAKE2b-256 |
524ce5539743c4e90bf0a93c489667b1eee49d180ab888eb575a90ae51143697
|
File details
Details for the file mvtToPng-1.0.1-py3-none-any.whl.
File metadata
- Download URL: mvtToPng-1.0.1-py3-none-any.whl
- Upload date:
- Size: 2.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3fdf600e1900cd25057118b0e485f99bd2027ee3b8b7221b4a9ffec343c61a2d
|
|
| MD5 |
1cf1704a0e503debef48b16e1b33166f
|
|
| BLAKE2b-256 |
316eaf94d325aa04c4948826019c94f48c1225a84513edb0df3f1edb452ec111
|