Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Construct and use map tile grids (a.k.a TileMatrixSet / TMS).
Documentation: https://developmentseed.org/morecantile/
Source Code: https://github.com/developmentseed/morecantile
Morecantile is like mercantile (the best tool to work with Web Mercator tile indexes), but with support for other TileMatrixSet grids.
Morecantile follows the OGC Two Dimensional Tile Matrix Set specification 2.0 found in https://docs.ogc.org/is/17-083r4/17-083r4.html
Morecantile Version | OGC Specification Version | Link |
---|---|---|
>=4.0 | 2.0 | https://docs.ogc.org/is/17-083r4/17-083r4.html |
=<3.0 | 1.0 | http://docs.opengeospatial.org/is/17-083r2/17-083r2.html |
$ python -m pip install -U pip
$ python -m pip install morecantile
# Or install from source:
$ python -m pip install -U pip
$ python -m pip install git+https://github.com/developmentseed/morecantile.git
import morecantile
tms = morecantile.tms.get("WebMercatorQuad")
# Get TMS bounding box
print(tms.xy_bbox)
>>> BoundingBox(
left=-20037508.342789244,
bottom=-20037508.34278919,
right=20037508.34278919,
top=20037508.342789244,
)
# Get the bounds for tile Z=4, X=10, Y=10 in the TMS's CRS (e.g epsg:3857)
print(tms.xy_bounds(morecantile.Tile(10, 10, 4)))
>>> BoundingBox(
left=5009377.085697308,
bottom=-7514065.628545959,
right=7514065.628545959,
top=-5009377.085697308,
)
# Get the bounds for tile Z=4, X=10, Y=10 in Geographic CRS (e.g epsg:4326)
print(tms.bounds(morecantile.Tile(10, 10, 4)))
>>> BoundingBox(
left=44.999999999999964,
bottom=-55.776573018667634,
right=67.4999999999999,
top=-40.97989806962009,
)
More info can be found at https://developmentseed.org/morecantile/usage/
morecantile
provides a set of default TileMatrixSets:
* TileMatrixSets with variable Matrix Width (see https://docs.ogc.org/is/17-083r4/17-083r4.html#toc15)
ref: https://schemas.opengis.net/tms/2.0/json/examples/tilematrixset/
See CHANGES.md.
See CONTRIBUTING.md
See LICENSE
Created by Development Seed
FAQs
Construct and use map tile grids (a.k.a TileMatrixSet / TMS).
We found that morecantile demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.