Create GeoJSON geometries that bound the extents of valid data in a raster.
Project description
raster-footprint
Create GeoJSON geometries that bound valid raster data. Depends on rasterio and shapely.
Usage
pip install raster-footprint
Create or manipulate GeoJSON with the CLI:
raster-footprint --help
usage: raster-footprint [-h] {create,densify,reproject,simplify} ...
options:
-h, --help show this help message and exit
commands:
{create,densify,reproject,simplify}
create Create a raster footprint
densify Densify a Polygon or MultiPolygon
reproject Reproject a Polygon or MultiPolygon
simplify Simplify a Polygon or MultiPolygon
Import raster_footprint
functions into your Python script:
from raster_footprint import footprint_from_href
footprint = footprint_from_href(
"my_raster.tif",
densify_distance=100,
simplify_tolerance=0.001,
holes=False
)
See the API documentation for available functions and options.
Developing
Clone and install in editable mode with the development optional dependencies:
git clone https://github.com/pjhartzell/raster-footprint
cd raster-footprint
pip install -e ".[dev,docs]"
We use pytest for tests:
pytest
We use Sphinx for docs:
make -C docs html
Contributing
Github issues and pull requests.
License
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
raster-footprint-0.2.0.tar.gz
(18.1 kB
view details)
Built Distribution
File details
Details for the file raster-footprint-0.2.0.tar.gz
.
File metadata
- Download URL: raster-footprint-0.2.0.tar.gz
- Upload date:
- Size: 18.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e582111ce4c8408060e3d746a305e70075de4ee240617e2a0bcca38f3c99beb9 |
|
MD5 | 1382d986cce025b996830fe0ab2d920e |
|
BLAKE2b-256 | 869536e9c62eb5dfba41df7f9c38108a13bba504cadf7be6aadb85f4c40a4816 |
File details
Details for the file raster_footprint-0.2.0-py3-none-any.whl
.
File metadata
- Download URL: raster_footprint-0.2.0-py3-none-any.whl
- Upload date:
- Size: 16.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 939fcffd16ea5af459db895e0a59d59cf5deea26c62fc98819795ae171e2b57a |
|
MD5 | 031b53e62d85710278127be90e16c7af |
|
BLAKE2b-256 | 12aa94d611656dd489ac6ff5c49c1019611b55b3dd5d0e61d9345665682e74bb |