PropagateUpDownIterative doesn't use convergence tolerance argument
Hello,
I have been attempting to run PropagateUpDownIterative with deficit + blockage models for large sites (>500 turbines) and have been finding the runtimes to be extremely high. I attempted to reduce this runtime by increasing the convergence_tolerance, but found this didn't have an effect.
Constructing PropagateUpDownIterative with a string convergence_tolerance does not result in an error, which indicates that it is not being used:
site = py_wake.examples.data.hornsrev1.Hornsrev1Site()
turbine = py_wake.examples.data.hornsrev1.V80()
PropagateUpDownIterative = py_wake.wind_farm_models.PropagateUpDownIterative
deficit = py_wake.deficit_models.TurboGaussianDeficit(use_effective_ws=True)
blockage = py_wake.deficit_models.SelfSimilarityDeficit2020(use_effective_ws=True)
model = PropagateUpDownIterative(site, turbine, wake_deficitModel=deficit, blockage_deficitModel=blockage,convergence_tolerance="convergence_tolerance")
res = model(*site.initial_position.T, wd = 30*np.arange(12), ws = np.arange(30))
Eyeballing the code, it seems like the _calc_wt_interaction method uses a hardcoded convergence tolerance of 1e-6 (line 512), unlike All2AllIterative's _calc_wt_interaction which has more complex logic on line 1009.