Skip to main content

Python wrapper for NOAA's WaveWatchIII Model

Project description

pyww3

https://img.shields.io/pypi/v/pyww3.svg https://img.shields.io/travis/caiostringari/pyww3.svg Documentation Status

Python wrapper for NOAA’s WaveWatchIII (WW3) Model.

This package wraps around the WW3’s executables by properly defining the namelists (.nml) required to drive the model’s executables.

Requirements

pyww3 requires WaveWatchIII to be properly compiled with netCDF4 available in your $PATH. Please follow the installation instructions from NOAA.

Programs supported: ww3_grid, ww3_prnc, ww3_shel, ww3_ounf, ww3_ounp and ww3_bounc.

Note that I don’t have plans to support programs that require ASCII input (such as ww3_outf) even tough they may have an associated namelist.

You will need python 3.7+ because of the extensive usage of dataclasses.

Getting Started

All the implemented classes have the same structure and methods. For example, to run simulation with ww3_shel you do:

import datetime
from pyww3.shel import WW3Shel
W = WW3Shel(nproc=8,
            runpath="tests/test_run/",
            mod_def="tests/test_data/GLOB_60_MIN.ww3grid",
            domain_start=datetime.datetime(2010, 1, 1, 0),
            domain_stop=datetime.datetime(2010, 1, 1, 2),
            input_forcing_winds=True,
            input_forcing_ice_conc=True,
            date_field_stride=3600,
            date_point_stride=3600,
            date_restart_stride=3600,
            type_point_file="tests/test_data/boundary_point_list.txt")
W.to_file() # writes ww3_shel.nml in the run path
W.run()  # run the simulation
print(W.stdout) # print the output given by WW3

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.

WW3 is maintained and distributed by NOAA’s Environmental Modeling Center (EMC).

Disclaimer

There is no warranty for the program, to the extent permitted by applicable law except when otherwise stated in writing the copyright holders and/or other parties provide the program “as is” without warranty of any kind, either expressed or implied, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose. the entire risk as to the quality and performance of the program is with you. should the program prove defective, you assume the cost of all necessary servicing, repair or correction.

History

0.1.0 (2021-08-25)

  • First release on PyPI.

Project details


Download files

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

Source Distribution

pyww3-0.1.4.tar.gz (50.1 kB view details)

Uploaded Source

File details

Details for the file pyww3-0.1.4.tar.gz.

File metadata

  • Download URL: pyww3-0.1.4.tar.gz
  • Upload date:
  • Size: 50.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/3.10.0 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.8.11

File hashes

Hashes for pyww3-0.1.4.tar.gz
Algorithm Hash digest
SHA256 5afc54b82cb7b76dde02fd63b610b5c18c5802a79c8780cf630618c687e25635
MD5 8898f4fc272cbd909ffbec2983097bd4
BLAKE2b-256 0f8ee9a74cdf39f711578a2b4b8afd6f13e3572633a333ffbc3a5d413c2412fa

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page