gnome.environment.tide

module contains objects that contain weather related data. For example, the Wind object defines the Wind conditions for the spill

Module Contents

Classes

Tide

todo: baseclass called ScaleTimeseries (or something like that)

Functions

_get_shio_yeardata_limits()

Attributes

SHIO_YEARDATA_LIMITS

gnome.environment.tide._get_shio_yeardata_limits()
gnome.environment.tide.SHIO_YEARDATA_LIMITS
class gnome.environment.tide.Tide(filename, yeardata=os.path.join(os.path.dirname(gnome.__file__), 'data', 'yeardata'), scale_factor=None, **kwargs)

Bases: gnome.environment.environment.Environment

todo: baseclass called ScaleTimeseries (or something like that) ScaleCurrent Define the tide for a spill

Currently, this internally defines and uses the CyShioTime object, which is a cython wrapper around the C++ Shio object

Tide information can be obtained from a filename or set as a timeseries (timeseries is NOT TESTED YET)

It requires one of the following to initialize:

  1. ‘timeseries’ assumed to be in ‘uv’ format (NOT TESTED/IMPLEMENTED OR USED YET)

  2. a ‘filename’ containing a header that defines units amongst other meta data

Parameters:
  • timeseries (numpy.ndarray with dtype=datetime_value_1d) – numpy array containing tide data

  • units – units associated with the timeseries data. If ‘filename’ is given, then units are read in from the filename. unit conversion - NOT IMPLEMENTED YET

  • filename – path to a long wind filename from which to read wind data

  • yeardata='gnome/data/yeardata/' – path to yeardata used for Shio data.

property extrapolation_is_allowed
property data_start
property data_stop
property yeardata
_ref_as = 'tide'
_schema
scale_factor
_obj_to_create(filename)

open file, read a few lines to determine if it is an ossm file or a shio file