Skip to main content
Copyright (c) 2015 pyoceans

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


Description: gridgeo
-------

.. image:: https://travis-ci.org/pyoceans/gridgeo.svg?branch=master
:target: https://travis-ci.org/pyoceans/gridgeo

.. image:: https://zenodo.org/badge/5715/pyoceans/gridgeo.svg
:target: https://zenodo.org/badge/latestdoi/5715/pyoceans/gridgeo

Convert ocean numerical models grids,
including UGRID and SGRID compliant files,
to a variety of geo-like objects: GeoJSON, and shapefile.

For some usage examples check the notebook folder:

https://github.com/pyoceans/gridgeo/tree/master/notebooks
Changelog
---------

Version 1.3.0

* Implemented most of netCDF4.Variable methods and properties in CFVariable.
Things like var.shape or var.size will work by default without the need to
request the original variable object.

Version 1.2.0

* Return the array of polygons and the shapely geometry.
* Parse the CRS using the CF grid_mapping attribute.
* Use the newer and faster unary_union instead of cascaded_union to compute the grid outline.

Version 1.0.1

* Cast connectivity array to int.

Version 1.0.0

* Construct the grid based on the variables rather the datasets.
The variables are CF's smallest unit and the only way to get a unique valid grid for SGRID.
* Dropped the dependency on iris, cartopy, pysgrid, and pyugrid.
* Dropped raster object in lieu of the actual x,y or triangle data for plotting.
* Added an option to reduce the precision for the GeoJSON.
* Grid parsing is now done with a grid-aware CFVariable object.
* Dropped parsing grid from iris.cube.
* Grids names are 'ugrid', 'sgrid', 'unknown_1d', and 'unknown_2d'.

Version 0.2.1

* Use latest pysgrid API.

Version 0.2.0

* Parse iris cubes with more than one X, Y axis.

Version 0.1.0

* Added a properties for raster representation (via the rasterize method)
and vector outline (via shapely's' cascaded_union).
* Re-factor the package into utilities.py and gridgeo.py.
* Removed precision argument. (Created degenerated polygons.)
* The __repr__ now return the original grid __repr__ if u/s-grid
or the original nc object if the grid is "unknown."
* Simplified the GridGeo class.
(Moved all the loading stuff to load_grid.)
* Caching expensive computations.

Version 0.0.1

* First version of `gridgeo`.

Keywords: geojson,shapefile,ocean models,ugrid,sgrid
Platform: any
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3.6
Classifier: Topic :: Scientific/Engineering

Download files

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

Source Distribution

gridgeo-1.3.0.tar.gz (26.0 kB view details)

Uploaded Source

Built Distribution

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

gridgeo-1.3.0-py3-none-any.whl (10.7 kB view details)

Uploaded Python 3

File details

Details for the file gridgeo-1.3.0.tar.gz.

File metadata

  • Download URL: gridgeo-1.3.0.tar.gz
  • Upload date:
  • Size: 26.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for gridgeo-1.3.0.tar.gz
Algorithm Hash digest
SHA256 74d7fd515adf263b6682cc1989d8f115e2de3f308d33b6e226e9ee40f68e6150
MD5 d7a0c292eea2f69510345111d22592bd
BLAKE2b-256 84f6ec2812fd3eff2ba344e63743af370fc00713b9bbccec8a2169e721ca5706

See more details on using hashes here.

File details

Details for the file gridgeo-1.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for gridgeo-1.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4b67b2175cc93ff97e7785aa766058cb30ba4e05db16873c30096e9bacf1743b
MD5 6d07790aa80a32ad5bb033d88c87ec2f
BLAKE2b-256 ff7df8e33f9882bc8ffe36929b5bac0f9f28863de032d8cf7f81ff4d34f60de1

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