xugrid


Namexugrid JSON
Version 0.9.0 PyPI version JSON
download
home_page
SummaryXarray extension for unstructured grids
upload_time2024-02-15 08:22:18
maintainer
docs_urlNone
author
requires_python>=3.9
licenseMIT
keywords mesh ugrid unstructured grid xarray
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Xugrid
======

.. image:: https://img.shields.io/github/actions/workflow/status/deltares/xugrid/ci.yml
   :target: https://github.com/deltares/xugrid/actions?query=workflows%3Aci
.. image:: https://img.shields.io/codecov/c/github/deltares/xugrid.svg
   :target: https://app.codecov.io/gh/deltares/xugrid
.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
   :target: https://github.com/psf/black
.. image:: https://zenodo.org/badge/DOI/10.5281/zenodo.10534099.svg
  :target: https://doi.org/10.5281/zenodo.10534099

**This is a work in progress.** `See documentation <https://deltares.github.io/xugrid/>`_.

Xarray extension to work with 2D unstructured grids, for data and topology
stored according to `UGRID conventions
<https://ugrid-conventions.github.io/ugrid-conventions>`_.

Processing structured data with xarray is convenient and efficient. The goal of
Xugrid is to extend this ease to unstructured grids.

.. code:: python

  import matplotlib.pyplot as plt
  import xugrid

  # Get some sample data as a xugrid UgridDataArray
  uda = xugrid.data.elevation_nl()

  # Get a cross-section
  section_y = 475_000.0
  section = uda.ugrid.sel(y=section_y)

  # Plot unstructured grid and cross section
  fig, (ax0, ax1) = plt.subplots(figsize=(22.6, 10), ncols=2)
  uda.ugrid.plot(ax=ax0, vmin=-20, vmax=90, cmap="terrain")
  ax0.axhline(y=section_y, color="red")
  section.plot(ax=ax1, x="mesh2d_face_x")

.. image:: https://raw.githubusercontent.com/Deltares/xugrid/main/docs/_static/xugrid-demo.png
  :target: https://github.com/deltares/xugrid

Installation
------------

Install via conda from the conda-forge channel:

.. code:: console

  conda install -c conda-forge xugrid

Or from the Python Package Index:

.. code:: console

  pip install xugrid

Documentation
-------------

.. image:: https://img.shields.io/github/actions/workflow/status/deltares/xugrid/ci.yml?style=flat-square
  :target: https://deltares.github.io/xugrid/

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "xugrid",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": "Huite Bootsma <huite.bootsma@deltares.nl>",
    "keywords": "mesh,ugrid,unstructured grid,xarray",
    "author": "",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/4a/92/06f615742712030db3f6d11c6f054ec78f4a0004845ede81b011dde46226/xugrid-0.9.0.tar.gz",
    "platform": null,
    "description": "Xugrid\n======\n\n.. image:: https://img.shields.io/github/actions/workflow/status/deltares/xugrid/ci.yml\n   :target: https://github.com/deltares/xugrid/actions?query=workflows%3Aci\n.. image:: https://img.shields.io/codecov/c/github/deltares/xugrid.svg\n   :target: https://app.codecov.io/gh/deltares/xugrid\n.. image:: https://img.shields.io/badge/code%20style-black-000000.svg\n   :target: https://github.com/psf/black\n.. image:: https://zenodo.org/badge/DOI/10.5281/zenodo.10534099.svg\n  :target: https://doi.org/10.5281/zenodo.10534099\n\n**This is a work in progress.** `See documentation <https://deltares.github.io/xugrid/>`_.\n\nXarray extension to work with 2D unstructured grids, for data and topology\nstored according to `UGRID conventions\n<https://ugrid-conventions.github.io/ugrid-conventions>`_.\n\nProcessing structured data with xarray is convenient and efficient. The goal of\nXugrid is to extend this ease to unstructured grids.\n\n.. code:: python\n\n  import matplotlib.pyplot as plt\n  import xugrid\n\n  # Get some sample data as a xugrid UgridDataArray\n  uda = xugrid.data.elevation_nl()\n\n  # Get a cross-section\n  section_y = 475_000.0\n  section = uda.ugrid.sel(y=section_y)\n\n  # Plot unstructured grid and cross section\n  fig, (ax0, ax1) = plt.subplots(figsize=(22.6, 10), ncols=2)\n  uda.ugrid.plot(ax=ax0, vmin=-20, vmax=90, cmap=\"terrain\")\n  ax0.axhline(y=section_y, color=\"red\")\n  section.plot(ax=ax1, x=\"mesh2d_face_x\")\n\n.. image:: https://raw.githubusercontent.com/Deltares/xugrid/main/docs/_static/xugrid-demo.png\n  :target: https://github.com/deltares/xugrid\n\nInstallation\n------------\n\nInstall via conda from the conda-forge channel:\n\n.. code:: console\n\n  conda install -c conda-forge xugrid\n\nOr from the Python Package Index:\n\n.. code:: console\n\n  pip install xugrid\n\nDocumentation\n-------------\n\n.. image:: https://img.shields.io/github/actions/workflow/status/deltares/xugrid/ci.yml?style=flat-square\n  :target: https://deltares.github.io/xugrid/\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Xarray extension for unstructured grids",
    "version": "0.9.0",
    "project_urls": {
        "Code": "https://github.com/deltares/xugrid",
        "Home": "https://github.com/deltares/xugrid",
        "Issues": "https://github.com/deltares/xugrid/issues"
    },
    "split_keywords": [
        "mesh",
        "ugrid",
        "unstructured grid",
        "xarray"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c3b9eeedd3540b6f37963ebcbfc960f590102850d2023cd703b325c8e28d9ed8",
                "md5": "cb035aeb91bd165e54bb4a6bab80234f",
                "sha256": "349d38b5d81ff363d6ccf560cb42c6c7d3e130a3578288c407ff524a66b23c1e"
            },
            "downloads": -1,
            "filename": "xugrid-0.9.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "cb035aeb91bd165e54bb4a6bab80234f",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 121676,
            "upload_time": "2024-02-15T08:22:16",
            "upload_time_iso_8601": "2024-02-15T08:22:16.567205Z",
            "url": "https://files.pythonhosted.org/packages/c3/b9/eeedd3540b6f37963ebcbfc960f590102850d2023cd703b325c8e28d9ed8/xugrid-0.9.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4a9206f615742712030db3f6d11c6f054ec78f4a0004845ede81b011dde46226",
                "md5": "e18dc0bfac1126a363a65578694bd97a",
                "sha256": "3e191b6897efe52566255f42428d9774875256301027631a7b0cc4bf88ffe57a"
            },
            "downloads": -1,
            "filename": "xugrid-0.9.0.tar.gz",
            "has_sig": false,
            "md5_digest": "e18dc0bfac1126a363a65578694bd97a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 144851,
            "upload_time": "2024-02-15T08:22:18",
            "upload_time_iso_8601": "2024-02-15T08:22:18.711675Z",
            "url": "https://files.pythonhosted.org/packages/4a/92/06f615742712030db3f6d11c6f054ec78f4a0004845ede81b011dde46226/xugrid-0.9.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-02-15 08:22:18",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "deltares",
    "github_project": "xugrid",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "xugrid"
}
        
Elapsed time: 0.19315s