Skip to main content
https://github.com/pytroll/pycoast/workflows/CI/badge.svg?branch=main https://coveralls.io/repos/github/pytroll/pycoast/badge.svg?branch=main https://img.shields.io/pypi/v/pycoast.svg pre-commit.ci status

Python package for adding coastlines, borders, rivers, lakes, cities, and other overlays to raster images.

Installation

PyCoast can be installed from PyPI using pip:

pip install pycoast

Or with conda using the conda-forge channel:

conda install -c conda-forge pycoast

Example

>>> from PIL import Image
>>> from pycoast import ContourWriterAGG
>>> img = Image.open('BMNG_clouds_201109181715_areaT2.png')
>>> proj4_string = '+proj=stere +lon_0=8.00 +lat_0=50.00 +lat_ts=50.00 +ellps=WGS84'
>>> area_extent = (-3363403.31,-2291879.85,2630596.69,2203620.1)
>>> area_def = (proj4_string, area_extent)
>>> cw = ContourWriterAGG('/home/esn/data/gshhs')
>>> cw.add_coastlines(img, area_def, resolution='l', level=4)
>>> cw.add_rivers(img, area_def, level=5, outline='blue')
>>> cw.add_borders(img, area_def, outline=(255, 0, 0))
>>> img.show()

License

Copyright 2011 Pycoast developers

Licensed under the Apache License, Version 2.0 (the “License”); you may not use these files except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Metadata

Release files for pycoast 1.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pycoast 1.8.0
File Size Uploaded Provenance
pycoast-1.8.0.tar.gz 12.7 MB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for pycoast 1.8.0
File Interpreter ABI Platform
pycoast-1.8.0-py3-none-any.whl Python 3 none any Details

Total release size: 20.1 MB

Release files / pycoast-1.8.0.tar.gz

Download URL pycoast-1.8.0.tar.gz
Size 12.7 MB
Tags Source
SHA-256 checksum
How to use checksums
a98633b657b3113077072240c45300450be5860c6536362e4f93bbc3251b70d2
BLAKE2b-256 checksum
How to use checksums
2cb151aa5b90c8826b8816a750dd5a5a7ddb12ceddb9584331892eb9a37e744b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / pycoast-1.8.0-py3-none-any.whl

Download URL pycoast-1.8.0-py3-none-any.whl
Size 7.4 MB
Tags Python 3
SHA-256 checksum
How to use checksums
34e6c1ff5ef4a3f24d9cf4a371c8e61e1b1263e6bc81f104e81913d961155b58
BLAKE2b-256 checksum
How to use checksums
b8345b5034432fc49b72cb31f39c5ad7654e41ee6a76139df290d63662f59769
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Security for pycoast 1.8.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page