SEA-PY: Python Tools for Oceanographic Analysis

South Atlantic Bathymetry

A collaborative effort to organize and distribute
Python tools for the Oceanographic Community

time series plot

A collaborative effort to organize Python tools for the Oceanographic Community

The Bare Minimum

  • Python: Needs no introduction.
  • IPython: An enhanced interactive Python shell.
  • NumPy: Support for large, multi-dimensional arrays and matrices, along with a large library of high-level mathematical functions to operate on these arrays.
  • SciPy: Library of algorithms and mathematical tools for the Python programming language.
  • matplotlib: 2D plotting library which produces publication quality figures in a variety of hardcopy formats and interactive environments.

Useful Extras

  • Anaconda: A Python distribution that comes with a GUI for package management and a number of scientific data analysis tools pre-installed. Ideal for users who don’t want to manually install a lot of packages or environments.
  • Miniconda: A lightweight Python distribution that comes only with the necessities, leaving the majority of package installs to the user. Ideal for users who want full control over package management.
  • JupyterLab: An interactive notebook environment which features cell-based code execution and supports markdown within the cells. Included in the Anaconda distribution by default.
  • pandas: Data analysis library which features spreadsheet-like DataFrames to organize data and contains many built-in time series analysis tools.
  • spyder: Spyder is the Scientific PYthon Development EnviRonment. A more traditional IDE as compared to JupyterLab. Included in the Anaconda distribution by default.
  • xarray: Package for working with labelled multi-dimesional arrays while preserving metadata, built on pandas and NumPy.

Data Acquisition

Time Series Tools

  • Currents: CODAS, Lowered ADCP
  • dateutil: Provides powerful extensions to the standard datetime module.
  • pytides: Pytides is small Python package for the analysis and prediction of tides.
  • PyWavelets: Wavelet transform module.
  • tappy: Tidal analysis package.
  • ttide: A direct conversion of T_Tide to Python.
  • UTide: UTide - A project (in its early development phase) to create a Python implementation of the Matlab-based UTide tidal analysis tools.
  • wafo: Routines for statistical analysis and simulation of random waves and random loads.

Numerical Modeling Tools

  • okean: Ocean modelling and analysis tools.
  • PyFVCOM: PyFVCOM is a collection of various tools and utilities which can be used to extract, analyse and plot input and output files from FVCOM.
  • pygridgen: A Python interface to Pavel Sakov’s C-based Gridgen Orthogonal Grid Generation Package.
  • pyroms: Collection of tools to help with input and output files from the Regional Ocean Modeling System (ROMS).
  • PySeidon: Suite of tools for the tidal energy community and FVCOM users
  • TracPy: Fortran core of Tracmass + Python wrapping around the outside. TracPy is a toolbox for Lagrangian tracking on top of staggered C grid model output, and is currently set up to use directly with ROMS.

Mapping Tools

  • basemap: Matplotlib Basemap Toolkit. Warning: this package is being deprecated in favor of the Cartopy project.
  • cartopy: A library providing cartographic tools for python.
  • folium: Python Data. Leaflet.js Maps.
  • PySAL: Python Spatial Analysis Library.
  • sci-wms: A Python WMS service for geospatial gridded data.

Hydrographic Tools

  • argopy: Argo data access, manipulation and visualisation for standard users as well as Argo experts
  • cbsyst: Python module for calculating carbon and boron solution chem.
  • mixsea: Ocean mixing parameterizations in python.
  • narwhal: Experimental tools to organize, analyze, and plot CTD data, including GSW wrappers.
  • PyCO2SYS: Marine carbonate system calculations (translated and expanded from CO2SYS for MATLAB/Excel).
  • pygsw: C-wrapped alternative to python-gsw.
  • python-ctd: Tools to load hydrographic data as pandas DataFrame with some handy methods for data pre-processing and analysis.
  • python-gsw: A oceanographic toolbox of the International Thermodynamic Equation Of Seawater - 2010, (TEOS-10).
  • python-seawater: Python version of the CSIRO seawater toolbox (SEAWATER-3.3).

Data Interface Tools

  • h5py: Interface to the HDF5 library.
  • netcdf4-python: Python/numpy interface to netCDF
  • Pydap: Library implementing the Data Access Protocol.
  • pygrib: python GRIB (editions 1 and 2) reader.
  • PyNIO/PyNGL: File input/output
  • PyTables: Package for managing hierarchical datasets and designed to efficiently and easily cope with extremely large amounts of data.
  • python-blosc: Wrapper for the Blosc compressor.
  • python-hdf4: Python-HDF4: Python interface to the NCSA HDF4 library.

Plotting (beyond matplotlib)

  • bokeh: Bokeh is a Python interactive visualization library that targets modern web browsers for presentation.
  • cmocean: Beautiful colormaps for oceanography.
  • mayavi: Scripting for 3D plotting.
  • mpld3: The mpld3 project brings together Matplotlib, the popular Python-based graphing library, and D3js, the popular Javascript library for creating interactive data visualizations for the web.
  • ggplot: ggplot is a plotting system for Python based on R’s ggplot2 and the Grammar of Graphics. It is built for making professional looking, plots quickly with minimal code.
  • gnuplot-py: Package that interfaces to gnuplot, the popular open-source plotting program.
  • PyNGL: Scientific visualization.
  • scienceplots: Pre-made matplotlib styles for formatting figures for publication.

CDMs

  • Iris: A Python library for Meteorology and Climatology
  • paegan: Processing and Analysis for Numerical Data.

Atmosphere

  • airsea: Translation of the original AIR_SEA toolbox for Matlab.
  • atmqty: Methods to calculate atmospheric quantities (on the Earth) that are directly derivative (i.e. not requiring time integration or modeling) from standard state variables.
  • pyCOARE: An implementation of the COARE v3.5 bulk air-sea flux algorithm.

Climate

  • ccc-gistemp: Reimplementation of GISTEMP in Python for clarity.
  • CDAT: Climate Data Analysis Tools.
  • climpy: climpy module.
  • PyClimate: Designed to accomplish some usual tasks needed during the analysis of climate variability. It provides functions to handle simple I/O operations, handling of COARDS-compliante netCDF files, EOF analysis, SVD and CCA analysis of coupled data sets, some linear digital filters, kernel based probability density function estimation and access to DCDFLIB.C library

Statistics

  • pymc: Markov chain Monte Carlo for Python
  • RPy: Interface to the R Programming Language.
  • statsmodels: Statistical computations and models for use with SciPy.
  • scikit.learn: Module integrating classic machine learning algorithms in the tightly-knit world of scientific Python packages.

Miscellaneous Other Tools

  • Astropysics: Astrophysics utilities.
  • biopython: Tools for biological computation written in Python.
  • Bottleneck: Fast NumPy array functions written in Cython.
  • fwrap: Wraps FORTRAN code.
  • gmpy: A C-coded Python extension module that wraps the GMP library to provide to Python code fast multiprecision arithmetic (integer, rational, and float), random number generation, advanced number-theoretical functions, and more.
  • numexpr: Fast numerical array expression evaluator for Python and NumPy.
  • oceans: Misc functions for oceanographic data analysis.
  • openptv: OpenPTV is an open source particle tracking velocimetry consortium providing software and assistance with the 3D-PTV experiments, including the field deployments for oceanographers, limnologists and meteorologits.
  • OWSLib: OWSLib is a Python package for client programming with Open Geospatial Consortium (OGC) web service (hence OWS) interface standards, and their related content models.
  • PyEphem: Scientific-grade astronomical computations.
  • pyferret: Ferret is an interactive computer visualization and analysis environment designed to meet the needs of oceanographers and meteorologists.
  • pyoos: A Python library for collecting Met/Ocean observations.
  • pytroll: Python modules for the reading, interpretation, and writing of weather satellite data.
  • SciPy scikits: Scipy Toolkits are independent and separately installable projects hosted under a common namespace. Packages that are distributed in this way are here (instead of in monolithic scipy) for at least one of three general reasons. Each of these reasons use the same high-level namespace (scikits).
  • scitools: Contains many useful tools for scientific computing in Python. The package is built on top of other widely used packages such as NumPy, SciPy, ScientificPython, Matplotlib, Gnuplot, etc.
  • SymPy: Library for symbolic mathematics.
  • Topical Software: SciPy Topical Software.
  • uncertainties: Transparent calculations with uncertainties on the quantities involved (aka “error propagation”) ; fast calculation of derivatives.

Fun

  • OceanSound: Get the music from oceancolor images, through MODIS satellite.
  • slocum: A tool for ocean passage planning.