Simulation result for gridded XRSite
Hi,
I am trying to create an XRSite like this:
from py_wake.site import XRSite
f = [3.3228977011101515, 3.8504554174171535, 4.484932094155394, 5.07747099337619, 5.101348273107267, 4.041066887297613, 3.4230134672738903, 3.3709268289508145, 4.723267615900397, 8.241312249736007, 12.351743244804352, 9.177061622093035, 7.401010981108068, 8.523802434424937, 9.600140985777763, 7.309549203466966]
wd = np.linspace(0, 360, len(f), endpoint=False)
complex_grid_site = XRSite(
ds=xr.Dataset(
data_vars={'WS': (['y', 'x'], subset.data),
'P': ('wd', f)},
coords={'x': data_lon, 'y': data_lat, 'wd': wd}),
)
site = complex_grid_site
x,y = np.asarray([-8189695.0]), np.asarray([4920249.0]) # initialize with 1 turbine
windTurbines = WindTurbines.from_WindTurbine_lst([V80()])
wf_model = BastankhahGaussian(site, windTurbines)
print(wf_model)
sim_res = wf_model(x,y)
This throws this error: TypeError: unsupported operand type(s) for +: 'NoneType' and 'float'
I'm trying to initialize a site with gridded wind speed from model output and following the XRSite documentation for a site with gridded speedup information as well as Issue #100 (closed). I am also having trouble with sim_res when working with one of the pre-defined XRSite examples and wonder if I'm missing something. I also am having trouble with flow_map, where I'm running into a ValueError (where the Point is outside the range).
Edited by Mads M. Pedersen