Skip to main content

Render xarray timestacks into GIFs

Project description

GeoGIF

Documentation Status

Make GIFs from time-stacked xarray.DataArrays (time, [optional band], y, x), dead-simple.

from geogif import gif, dgif
gif(data_array)
dgif(dask_data_array).compute()

Animation of shoreline moving on the coast of Cape Cod

The "geo" part is a lie, actually. The arrays don't have to be geospatial in nature. But I called it GeoGIF because:

  1. Wanting to animate a time-stack of imagery (like you'd get from stackstac) is a common task in the earth-observation/geospatial world.
  2. I think GeoGIF is a hilarious idea1.

1: To ruin the joke, it sounds like GeoTIFF, a ubiquitous geospatial image format. If you also think this is a funny idea, and believe you'd have a better use for the name than I do, I'd happily cede it to you.

Installation

pip install geogif

Documentation

See https://geogif.readthedocs.io/en/latest/

Development

GeoGIF is managed by Poetry, so be sure that's installed first. To develop locally, first fork or clone the repo. Then, to set up a virtual environment and install the necessary dependencies:

cd geogif
poetry install -E tests -E docs

Running Tests

GeoGIF has some basic end-to-end tests, written with Hypothesis. To run:

pytest

This will take ~30 seconds (longer the first time), as Hypothesis generates fake data to root out possible errors.

Code style

GeoGIF is formatted with shed, in order to allow for as few opinions as possible.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

geogif-0.1.0.tar.gz (8.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

geogif-0.1.0-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file geogif-0.1.0.tar.gz.

File metadata

  • Download URL: geogif-0.1.0.tar.gz
  • Upload date:
  • Size: 8.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.7

File hashes

Hashes for geogif-0.1.0.tar.gz
Algorithm Hash digest
SHA256 bc6b0671dce0bc2487786dcd5ef14ab621c90566b048b75fccaca8b246480173
MD5 a995db7ddf8b8717c9a0ed3d71074bc1
BLAKE2b-256 e6b150fef7df39cf20f7a6a22c5edd3e7295f7d2b02bc05baec6962b67f4a553

See more details on using hashes here.

File details

Details for the file geogif-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: geogif-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.7

File hashes

Hashes for geogif-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d89f332777991f6636b0a0f06a425131ce7b4dff2e1901ee15256d438a567f22
MD5 396921834c408ff36c8ee0b0b72dd079
BLAKE2b-256 f78021a8ed12cc0c8110eb9dbd72561996ed6fb2c8b99cd2f66ce79cf1fd1b4e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page