Giter VIP home page Giter VIP logo

xroms's Introduction

xroms

Build Status Code Coverage License:MIT Documentation Status Code Style Status Conda Version Python Package Index

DOI

xroms contains functions for commonly used scripts for working with ROMS output in xarray.

There are functions to...

  • help read in model output with automatically-calculated z coordinates
  • calculate many derived variables with correct grid metrics in one line including:
    • horizontal speed
    • kinetic energy
    • eddy kinetic energy
    • vertical shear
    • vertical vorticity
    • Ertel potential vorticity
    • density as calculated in ROMS
    • potential density
    • buoyancy
    • $N^2$ (buoyancy frequency/vertical buoyancy gradient)
    • $M^2$ (horizontal buoyancy gradient)
  • useful functions including:
    • derivatives in all dimensions, accounting for curvilinear grids and sigma layers
    • grid metrics (i.e., grid lengths, areas, and volumes)
    • subset horizontal grid such that the staggered grids are consistent
    • easily change horizontal and vertical grids using xgcm grid objects
    • easily reorder to dimensional convention
    • slice along a fixed value
    • wrapper for interpolation in longitude/latitude and for fixed depths
    • mixed-layer depth
  • Demonstrations:
    • selecting data in many different ways
    • interpolation
    • changing time sampling
    • calculating climatologies
    • various calculations
  • provide/track attributes and coordinates through functions
    • wraps cf-xarray to generalize coordinate and dimension calling.
  • ability to automatically choose colormaps for plotting with xarray
    • wraps xcmocean for this

Installation

You need to have conda installed for these installation instructions. You'll have best results if you use the channel conda-forge, which you can prioritize with conda config --add channels conda-forge --force.

Install, the easy way

PyPI:

pip install xroms

conda-forge:

mamba install -c conda-forge xroms

Create environment if needed

As a first step, you can create an environment for this package with conda if you want. If you do this, you'll need to git clone the package first as below. Note that mamba and conda can be used interchangeably, but mamba is faster for installation.

mamba env create -f environment.yml

You can choose to install with conda the optional dependencies for full functionality:

conda install --file requirements-opt.txt

and to install optional dependency xcmocean:

pip install git+git://github.com/pangeo-data/xcmocean

Then choose one of the following to install xroms from GitHub:

  1. Clone xroms into a particular directory then install so that it is editable (-e)

    git clone [email protected]:xoceanmodel/xroms.git
    cd xroms
    pip install -e .
    
  2. Directly install xroms from github

    pip install git+git://github.com/xoceanmodel/xroms
    

xroms's People

Contributors

kthyng avatar hetland avatar dependabot[bot] avatar ocefpaf avatar christophrenkl avatar vrx- avatar

Stargazers

Uilliams Paz avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.