pywasp.wasp.wind_farm_flow_map

pywasp.wasp.wind_farm_flow_map(wwc, wtg_dict, wind_turbines, output_locs, wind_farm_model='PARK2_onshore', turbulence_intensity=None, shear=None, ws_stepsize=1.0, ws_upper_limit=None, ws_lower_limit=0.0, n_subsector=5, wtg_id=0, site_interp_method='nearest', site_interp_bounds='ignore', n_cpu_pywake=1)[source]

Generate a flow map around a wind farm using py_wake for wake and blockage effects. The map is calculated at the same points as the weibull wind climate(s) are provided.

Warning

This function is experimental and its signature may change.

Parameters:
  • wwc (Dataset) – Weibull Wind Climate Cuboid Dataset containing wind climates for all the turbine locations.

  • wtg_dict (dict) –

    A dict of wtg_keys and WTG xr.Datasets should be passed, a turbines

    dataset must be passed as well, and the key’s must match between the two.

  • wind_turbines (Dataset) – Wind Turbine locations, hub heights, group_id’s, and wtg_keys.

  • output_locs (Dataset) – Locations to calculate the flow map at. Must be a “cuboid” xr.Dataset with 3 spatial dimensions: ‘west_east’, ‘south_north’, ‘height’. The coordinates of the output locations must be covered by the cuboid spanned by the weibull wind climate(s).

  • wind_farm_model (str, function, optional) – Wind farm model to use for deficit calculations. Can Either be a name of a predefined wind farm model: “PARK1”, “PARK2_onshore”, “PARK2_offshore”, or a predefined py_wake wind_farm_model object. By default “PARK2_onshore” is used.

  • turbulence_intensity (float, optional) – Turbulence intensity to use for the AEP calculation. If not passed, the turbulence intensity from the WWC will be used. If turbulence intensity is passed, it will be used, and overwrite the turbulence intensity in the WWC, if present.

  • shear (float, optional) – shear to use for the AEP calculation. If not passed, the shear from the WWC will be used. If shear is passed, it will be used, and overwrite the shear in the WWC, if present.

  • ws_stepsize (float, optional) – Wind speed bins stepsize, by default 1.0

  • ws_upper_limit (float, optional) – Upper limit of wind speed range, by default None Which means the upper limit of the wind speed range will be the maximum

  • ws_lower_limit (float, optional) – Lower limit of wind speed range, by default 0.0

  • n_subsector (int, optional) – Number of subsectors to use per sector, by default 5

  • wtg_id (int, optional) – The wind turbine type to use for calculating the AEP flow map, by default 0, the first type The WTG is taken from the corresponding entry in the wind_turbines object.

  • site_interp_method (str, optional) – The interpolation method to use in py_wake XRSite, by default “nearest”

  • site_interp_bounds (str, optional) – The extrapolation method to use in py_wake XRSite, by default “ignore”

  • n_cpu_pywake (int, optional) – Number of CPUs to use in py_wake, by default 1

Returns:

Dataset – Wind farm flow map for the output_locs containing the variables:

  • potential_AEP_sector:

    Potential AEP in GWh for each sector

  • gross_AEP_sector:

    Gross AEP in GWh for each sector

  • AEP_deficit_sector:

    AEP deficit in units of fraction for each sector

  • wspd_sector:

    Average wind speed in m/s for each sector

  • wspd_eff_sector:

    Average effective wind speed in m/s for each sector

  • wspd_deficit_sector:

    Average wind speed deficit in units of fraction for each sector

  • turbulence_intensity_eff_sector:

    Average effective turbulence intensity for each sector

  • wdfreq:

    Wind direction frequency in units of fraction for each sector

  • potential_AEP:

    Potential AEP in GWh for each location

  • gross_AEP:

    Gross AEP in GWh for each location

  • AEP_deficit:

    AEP deficit in units of fraction for each location

  • wspd:

    Average wind speed in m/s for each location

  • wspd_eff:

    Average effective wind speed in m/s for each location

  • wspd_deficit:

    Average wind speed deficit in units of fraction for each location

  • turbulence_intensity_eff:

    Average effective turbulence intensity for each location

Raises:
  • TypeError – If output_locs is not a xr.Dataset

  • ValueError – If output_locs is not a “cuboid” xr.Dataset

  • ValueError – If wwc is not a “cuboid” xr.Dataset

  • ValueError – If output_locs is not covered by the cuboid spanned by the weibull wind climate(s)

  • ValueError – If the wind turbine locations are not covered by the cuboid spanned by the weibull wind climate(s)