reVX.offshore.assembly_areas.AssemblyAreas

class AssemblyAreas(assembly_areas, excl_fpath, ports_dset='ports_construction_nolimits')[source]

Bases: object

Class to compute the distance from port to assembly areas using the distance to port arrays produced using DistanceToPorts

Parameters:
  • assembly_areas (str | pandas.DataFrame) – DataFrame or path to csv or json containing assembly area meta and locational data

  • excl_fpath (str) – Path to exclusions .h5 file with distance to coast layer

Methods

distance_to_ports([assembly_dset])

Extact the least cost distance between assembly areas and all available port layers in excl_fpath.

run(assembly_areas, excl_fpath[, ...])

Compute the distance from port to assembly areas using the distance to port layers/arrays produced using DistanceToPorts.

Attributes

DIST_COL

assembly_areas

DataFrame with assembly area meta and locational data

property assembly_areas

DataFrame with assembly area meta and locational data

Returns:

pandas.DataFrame

distance_to_ports(assembly_dset=None)[source]

Extact the least cost distance between assembly areas and all available port layers in excl_fpath. Save value to assembly areas DataFrame

Parameters:

assembly_dset (str, optional) – Dataset name to save assembly area table to in excl_fpath, by default None

Returns:

assembly_areas (pandas.DataFrame) – Updated assembly area DataFrame with distance to all ports

classmethod run(assembly_areas, excl_fpath, ports_dset='ports_construction_nolimits', assembly_dset=None)[source]

Compute the distance from port to assembly areas using the distance to port layers/arrays produced using DistanceToPorts. Save to excl_fpath under given dataset name

Parameters:
  • assembly_areas (str | pandas.DataFrame) – DataFrame or path to csv or json containing assembly area meta and locational data

  • excl_fpath (str) – Path to exclusions .h5 file with distance to coast layer

  • ports_dset (str, optional) – Distance to ports layer/dataset name in excl_fpath, by default ‘ports_construction_nolimits’

  • assembly_dset (str, optional) – Dataset name to save assembly area table to in excl_fpath, by default None

Returns:

assembly_areas (pandas.DataFrame) – Updated assembly area DataFrame with distance to all ports