Skip to main content

Gibbs Seawater Oceanographic Package of TEOS-10

Project description

project, and are subject to src/c_gsw/LICENSE.

Sections of documentation text, as well as the function names and the
names of their inputs and outputs, and the algorithms, are ultimately
derived from the GSW-Matlab implementation and other work of the
TEOS-10 developers, and may be subject to additional restrictions.
See http://teos-10.org/ for more information.

Copyright Notice and Statement for the remainder of the gsw project,
which is this specific Python implementation:

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.

Download-URL: https://pypi.python.org/pypi/gsw/
Description: gsw Python package
==================

.. image:: https://travis-ci.org/TEOS-10/GSW-Python.svg?branch=master
:target: https://travis-ci.org/TEOS-10/GSW-Python
.. image:: https://anaconda.org/conda-forge/gsw/badges/installer/conda.svg
:target: https://conda.anaconda.org/conda-forge

This Python implementation of the Thermodynamic Equation of
Seawater 2010 (TEOS-10) is based primarily on numpy ufunc wrappers of
the GSW-C implementation. We expect it to replace the original
`python-gsw <https://github.com/TEOS-10/python-gsw/>`__
pure-python implementation after a brief overlap period.
The primary reasons for this change are that by building on the
C implementation we reduce code duplication and we gain an immediate
update to the 75-term equation. Additional benefits include a
major increase in speed, a reduction in memory usage, and the
inclusion of more functions. The penalty is that a C (or MSVC C++ for
Windows) compiler is required to build the package from source.

**Warning: this is for Python >=3.5 only.**

**Warning:** the only *official* TEOS-10 implementations are
provided as zipfiles at <http://www.teos-10.org/software.htm>.

Documentation is provided at <https://teos-10.github.io/GSW-Python/>.

For the core functionality, we use an auto-generated C extension
module to wrap the C functions as numpy
`ufuncs <https://docs.scipy.org/doc/numpy/reference/ufuncs.html>`__,
and then use an
autogenerated Python module to add docstrings and handle masked
arrays. 161 scalar C functions with only double-precision
arguments and return values are wrapped as ufuncs, and 155 of
these are exposed in the ``gsw`` namespace with an additional
wrapper in Python.

A hand-written wrapper is used for one C function, and others
are re-implemented directly in Python instead of being wrapped.
Additional functions present in GSW-Matlab but not in GSW-C may
be re-implemented in Python, but there is no expectation that
all such functions will be provided.

The package can be installed from a clone of the repo using
``pip install .``. It is neither necessary nor recommended
to run the code generators, and no instructions are provided
for them; their output is
included in the repo. You will need a suitable compiler: gcc or
clang for unix-like systems, or the MSVC compiler set used for Python
itself on Windows. For Windows, some of the source code has been
modified to C++ because the MSVC C compiler does not support the
C99 complex data type used in original GSW-C.

To test, after installation, run "py.test" from the source directory.

Keywords: oceanography,seawater,TEOS-10
Platform: any
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Topic :: Scientific/Engineering
Requires-Python: >=3.5

Project details


Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
gsw-3.2.1.tar.gz (2.4 MB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page