hydroflows.methods.coastal.get_gtsm_data#

Method for fetching GTSM waterlevel and surge timeseries for a given region.

class hydroflows.methods.coastal.get_gtsm_data.GetGTSMData(region: Path, gtsm_catalog: Path, data_root: Path = PosixPath('data/input'), **params)[source]#

Method for fetching GTSM waterlevel and surge timeseries for a given region.

Parameters:
  • region (Path) – Path to file containing area of interest geometry. Centroid is used to look for nearest GTSM station.

  • data_root (Path, optional) – The root folder where data is stored, by default “data/input/forcing_data/waterlevel”

pydantic model hydroflows.methods.coastal.get_gtsm_data.Input[source]#

Input parameters for the GetGTSMData method.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Fields:
field gtsm_catalog: Annotated[Path, AfterValidator(func=filedir_validator)] [Required]#

Path to HydroMT data catalog describing GTSM data.

field region: Path [Required]#

Path to file containing area of interest geometry. Centroid is used to look for nearest GTSM station.

model_post_init(context: Any, /) None#

This function is meant to behave like a BaseModel method to initialise private attributes.

It takes context as an argument since that’s what pydantic-core passes when calling it.

Parameters:
  • self – The BaseModel instance.

  • context – The context.

pydantic model hydroflows.methods.coastal.get_gtsm_data.Output[source]#

Output parameters for the GetGTSMData method.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Fields:
field bnd_locations: Path [Required]#

Path to output file containing point locations associated with the timeseries.

field surge_nc: Path [Required]#

Path to output file containing surge .nc timeseries

field tide_nc: Path [Required]#

Path to output file containing tide .nc timeseries

field waterlevel_nc: Path [Required]#

Path to output file containing waterlevel .nc timeseries

model_post_init(context: Any, /) None#

This function is meant to behave like a BaseModel method to initialise private attributes.

It takes context as an argument since that’s what pydantic-core passes when calling it.

Parameters:
  • self – The BaseModel instance.

  • context – The context.

pydantic model hydroflows.methods.coastal.get_gtsm_data.Params[source]#

Params for the GetGTSMData method.

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

Fields:
field buffer: float = 2000#

Buffer around region to look for GTSM stations, [m]

field catalog_key: str = 'gtsm_codec_reanalysis'#

Data catalog key for GTSM data.

field data_root: Annotated[Path, AfterValidator(func=outputdirpath_validator)] = PosixPath('data/input')#
field end_time: datetime = datetime.datetime(2018, 12, 31, 0, 0)#

End date for the fetched timeseries

field start_time: datetime = datetime.datetime(1979, 1, 1, 0, 0)#

Start date for the fetched timeseries

model_post_init(context: Any, /) None#

This function is meant to behave like a BaseModel method to initialise private attributes.

It takes context as an argument since that’s what pydantic-core passes when calling it.

Parameters:
  • self – The BaseModel instance.

  • context – The context.