foxes 1.2.5__py3-none-any.whl → 1.4__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of foxes might be problematic. Click here for more details.

Files changed (201) hide show
  1. docs/source/conf.py +3 -3
  2. examples/abl_states/run.py +2 -2
  3. examples/compare_rotors_pwakes/run.py +1 -1
  4. examples/compare_wakes/run.py +1 -2
  5. examples/dyn_wakes/run.py +29 -6
  6. examples/induction/run.py +3 -3
  7. examples/multi_height/run.py +1 -1
  8. examples/power_mask/run.py +2 -2
  9. examples/quickstart/run.py +16 -0
  10. examples/random_timeseries/run.py +3 -4
  11. examples/scan_row/run.py +3 -3
  12. examples/sequential/run.py +33 -10
  13. examples/single_state/run.py +3 -4
  14. examples/states_lookup_table/run.py +3 -3
  15. examples/streamline_wakes/run.py +27 -4
  16. examples/tab_file/run.py +3 -3
  17. examples/timelines/run.py +29 -5
  18. examples/timeseries/run.py +3 -3
  19. examples/timeseries_slurm/run.py +3 -3
  20. examples/wind_rose/run.py +3 -3
  21. examples/yawed_wake/run.py +16 -8
  22. foxes/__init__.py +22 -18
  23. foxes/algorithms/__init__.py +6 -6
  24. foxes/algorithms/downwind/__init__.py +2 -2
  25. foxes/algorithms/downwind/downwind.py +53 -27
  26. foxes/algorithms/downwind/models/__init__.py +6 -6
  27. foxes/algorithms/downwind/models/farm_wakes_calc.py +22 -14
  28. foxes/algorithms/downwind/models/init_farm_data.py +4 -5
  29. foxes/algorithms/downwind/models/point_wakes_calc.py +7 -13
  30. foxes/algorithms/downwind/models/reorder_farm_output.py +5 -1
  31. foxes/algorithms/downwind/models/set_amb_point_results.py +7 -7
  32. foxes/algorithms/iterative/__init__.py +7 -3
  33. foxes/algorithms/iterative/iterative.py +1 -2
  34. foxes/algorithms/iterative/models/__init__.py +7 -3
  35. foxes/algorithms/iterative/models/farm_wakes_calc.py +15 -8
  36. foxes/algorithms/sequential/__init__.py +3 -3
  37. foxes/algorithms/sequential/models/__init__.py +2 -2
  38. foxes/algorithms/sequential/models/seq_state.py +0 -18
  39. foxes/algorithms/sequential/sequential.py +8 -22
  40. foxes/config/__init__.py +5 -1
  41. foxes/constants.py +22 -0
  42. foxes/core/__init__.py +45 -22
  43. foxes/core/algorithm.py +0 -1
  44. foxes/core/data.py +56 -29
  45. foxes/core/engine.py +28 -14
  46. foxes/core/farm_controller.py +2 -2
  47. foxes/core/farm_data_model.py +1 -0
  48. foxes/core/ground_model.py +4 -13
  49. foxes/core/model.py +5 -5
  50. foxes/core/partial_wakes_model.py +147 -10
  51. foxes/core/point_data_model.py +2 -3
  52. foxes/core/rotor_model.py +42 -38
  53. foxes/core/states.py +4 -50
  54. foxes/core/turbine.py +2 -1
  55. foxes/core/wake_deflection.py +130 -0
  56. foxes/core/wake_model.py +222 -9
  57. foxes/core/wake_superposition.py +122 -4
  58. foxes/core/wind_farm.py +6 -6
  59. foxes/data/__init__.py +7 -2
  60. foxes/data/states/weibull_sectors_12.csv +13 -0
  61. foxes/data/states/weibull_sectors_12.nc +0 -0
  62. foxes/engines/__init__.py +14 -15
  63. foxes/engines/dask.py +39 -14
  64. foxes/engines/numpy.py +0 -3
  65. foxes/input/__init__.py +3 -3
  66. foxes/input/farm_layout/__init__.py +8 -8
  67. foxes/input/farm_layout/from_csv.py +1 -1
  68. foxes/input/farm_layout/ring.py +0 -1
  69. foxes/input/states/__init__.py +22 -11
  70. foxes/input/states/create/__init__.py +3 -2
  71. foxes/input/states/field_data_nc.py +48 -84
  72. foxes/input/states/multi_height.py +40 -60
  73. foxes/input/states/one_point_flow.py +22 -25
  74. foxes/input/states/scan.py +6 -19
  75. foxes/input/states/single.py +6 -18
  76. foxes/input/states/states_table.py +25 -44
  77. foxes/input/states/weibull_sectors.py +225 -0
  78. foxes/input/states/wrg_states.py +151 -37
  79. foxes/input/yaml/__init__.py +9 -3
  80. foxes/input/yaml/dict.py +19 -19
  81. foxes/input/yaml/windio/__init__.py +10 -5
  82. foxes/input/yaml/windio/read_attributes.py +2 -2
  83. foxes/input/yaml/windio/read_farm.py +5 -5
  84. foxes/input/yaml/windio/read_fields.py +4 -2
  85. foxes/input/yaml/windio/read_site.py +52 -0
  86. foxes/input/yaml/windio/windio.py +1 -1
  87. foxes/models/__init__.py +15 -14
  88. foxes/models/axial_induction/__init__.py +2 -2
  89. foxes/models/farm_controllers/__init__.py +1 -1
  90. foxes/models/farm_models/__init__.py +1 -1
  91. foxes/models/ground_models/__init__.py +3 -2
  92. foxes/models/ground_models/wake_mirror.py +3 -3
  93. foxes/models/model_book.py +175 -49
  94. foxes/models/partial_wakes/__init__.py +6 -6
  95. foxes/models/partial_wakes/axiwake.py +30 -5
  96. foxes/models/partial_wakes/centre.py +47 -0
  97. foxes/models/partial_wakes/rotor_points.py +45 -9
  98. foxes/models/partial_wakes/segregated.py +2 -20
  99. foxes/models/partial_wakes/top_hat.py +27 -2
  100. foxes/models/point_models/__init__.py +4 -4
  101. foxes/models/rotor_models/__init__.py +3 -3
  102. foxes/models/rotor_models/centre.py +6 -4
  103. foxes/models/turbine_models/__init__.py +11 -11
  104. foxes/models/turbine_models/set_farm_vars.py +0 -1
  105. foxes/models/turbine_types/PCt_file.py +0 -2
  106. foxes/models/turbine_types/PCt_from_two.py +0 -2
  107. foxes/models/turbine_types/__init__.py +9 -9
  108. foxes/models/vertical_profiles/__init__.py +7 -7
  109. foxes/models/wake_deflections/__init__.py +3 -0
  110. foxes/models/{wake_frames/yawed_wakes.py → wake_deflections/bastankhah2016.py} +32 -111
  111. foxes/models/wake_deflections/jimenez.py +277 -0
  112. foxes/models/wake_deflections/no_deflection.py +94 -0
  113. foxes/models/wake_frames/__init__.py +6 -7
  114. foxes/models/wake_frames/dynamic_wakes.py +12 -3
  115. foxes/models/wake_frames/rotor_wd.py +3 -1
  116. foxes/models/wake_frames/seq_dynamic_wakes.py +45 -8
  117. foxes/models/wake_frames/streamlines.py +8 -6
  118. foxes/models/wake_frames/timelines.py +19 -3
  119. foxes/models/wake_models/__init__.py +7 -7
  120. foxes/models/wake_models/dist_sliced.py +50 -84
  121. foxes/models/wake_models/gaussian.py +20 -0
  122. foxes/models/wake_models/induction/__init__.py +5 -5
  123. foxes/models/wake_models/induction/rankine_half_body.py +30 -71
  124. foxes/models/wake_models/induction/rathmann.py +65 -64
  125. foxes/models/wake_models/induction/self_similar.py +65 -68
  126. foxes/models/wake_models/induction/self_similar2020.py +0 -3
  127. foxes/models/wake_models/induction/vortex_sheet.py +71 -75
  128. foxes/models/wake_models/ti/__init__.py +2 -2
  129. foxes/models/wake_models/ti/crespo_hernandez.py +5 -3
  130. foxes/models/wake_models/ti/iec_ti.py +6 -4
  131. foxes/models/wake_models/top_hat.py +58 -7
  132. foxes/models/wake_models/wind/__init__.py +6 -4
  133. foxes/models/wake_models/wind/bastankhah14.py +25 -7
  134. foxes/models/wake_models/wind/bastankhah16.py +35 -3
  135. foxes/models/wake_models/wind/jensen.py +15 -2
  136. foxes/models/wake_models/wind/turbopark.py +28 -2
  137. foxes/models/wake_superpositions/__init__.py +18 -9
  138. foxes/models/wake_superpositions/ti_linear.py +4 -4
  139. foxes/models/wake_superpositions/ti_max.py +4 -4
  140. foxes/models/wake_superpositions/ti_pow.py +4 -4
  141. foxes/models/wake_superpositions/ti_quadratic.py +4 -4
  142. foxes/models/wake_superpositions/wind_vector.py +257 -0
  143. foxes/models/wake_superpositions/ws_linear.py +9 -10
  144. foxes/models/wake_superpositions/ws_max.py +8 -8
  145. foxes/models/wake_superpositions/ws_pow.py +8 -8
  146. foxes/models/wake_superpositions/ws_product.py +4 -4
  147. foxes/models/wake_superpositions/ws_quadratic.py +8 -8
  148. foxes/output/__init__.py +21 -19
  149. foxes/output/farm_layout.py +14 -6
  150. foxes/output/farm_results_eval.py +51 -27
  151. foxes/output/flow_plots_2d/__init__.py +2 -2
  152. foxes/output/flow_plots_2d/get_fig.py +4 -2
  153. foxes/output/rose_plot.py +23 -5
  154. foxes/output/seq_plugins/__init__.py +2 -2
  155. foxes/output/seq_plugins/seq_flow_ani_plugin.py +0 -3
  156. foxes/output/seq_plugins/seq_wake_debug_plugin.py +0 -1
  157. foxes/output/slice_data.py +16 -19
  158. foxes/output/turbine_type_curves.py +7 -8
  159. foxes/utils/__init__.py +37 -19
  160. foxes/utils/abl/__init__.py +4 -4
  161. foxes/utils/cubic_roots.py +1 -1
  162. foxes/utils/data_book.py +4 -3
  163. foxes/utils/dict.py +3 -3
  164. foxes/utils/exec_python.py +5 -5
  165. foxes/utils/factory.py +1 -3
  166. foxes/utils/geom2d/__init__.py +7 -5
  167. foxes/utils/geopandas_utils.py +2 -2
  168. foxes/utils/pandas_utils.py +4 -3
  169. foxes/utils/tab_files.py +0 -1
  170. foxes/utils/weibull.py +28 -0
  171. foxes/utils/wrg_utils.py +3 -1
  172. foxes/utils/xarray_utils.py +9 -2
  173. foxes/variables.py +67 -9
  174. {foxes-1.2.5.dist-info → foxes-1.4.dist-info}/METADATA +14 -21
  175. foxes-1.4.dist-info/RECORD +320 -0
  176. {foxes-1.2.5.dist-info → foxes-1.4.dist-info}/WHEEL +1 -1
  177. tests/0_consistency/iterative/test_iterative.py +2 -3
  178. tests/0_consistency/partial_wakes/test_partial_wakes.py +2 -2
  179. tests/1_verification/flappy_0_6/PCt_files/flappy/run.py +2 -3
  180. tests/1_verification/flappy_0_6/PCt_files/test_PCt_files.py +48 -56
  181. tests/1_verification/flappy_0_6/abl_states/flappy/run.py +0 -1
  182. tests/1_verification/flappy_0_6/abl_states/test_abl_states.py +33 -36
  183. tests/1_verification/flappy_0_6/partial_top_hat/flappy/run.py +0 -1
  184. tests/1_verification/flappy_0_6/partial_top_hat/test_partial_top_hat.py +0 -2
  185. tests/1_verification/flappy_0_6/row_Jensen_linear_centre/test_row_Jensen_linear_centre.py +3 -3
  186. tests/1_verification/flappy_0_6/row_Jensen_linear_tophat/test_row_Jensen_linear_tophat.py +3 -4
  187. tests/1_verification/flappy_0_6/row_Jensen_linear_tophat_IECTI2005/test_row_Jensen_linear_tophat_IECTI_2005.py +3 -4
  188. tests/1_verification/flappy_0_6/row_Jensen_linear_tophat_IECTI2019/test_row_Jensen_linear_tophat_IECTI_2019.py +3 -4
  189. tests/1_verification/flappy_0_6/row_Jensen_quadratic_centre/test_row_Jensen_quadratic_centre.py +3 -4
  190. tests/1_verification/flappy_0_6_2/grid_rotors/flappy/run.py +0 -2
  191. tests/1_verification/flappy_0_6_2/grid_rotors/test_grid_rotors.py +3 -3
  192. tests/1_verification/flappy_0_6_2/row_Bastankhah_Crespo/test_row_Bastankhah_Crespo.py +3 -3
  193. tests/1_verification/flappy_0_6_2/row_Bastankhah_linear_centre/flappy/run.py +0 -1
  194. tests/1_verification/flappy_0_6_2/row_Bastankhah_linear_centre/test_row_Bastankhah_linear_centre.py +3 -4
  195. tests/3_examples/test_examples.py +3 -2
  196. foxes/output/round.py +0 -10
  197. foxes/utils/pandas_helpers.py +0 -178
  198. foxes-1.2.5.dist-info/RECORD +0 -312
  199. {foxes-1.2.5.dist-info → foxes-1.4.dist-info}/entry_points.txt +0 -0
  200. {foxes-1.2.5.dist-info → foxes-1.4.dist-info/licenses}/LICENSE +0 -0
  201. {foxes-1.2.5.dist-info → foxes-1.4.dist-info}/top_level.txt +0 -0
@@ -179,7 +179,7 @@ def read_shp_polygons(
179
179
  utmz = None
180
180
  utml = None
181
181
  apply_utm = False
182
- if isinstance(to_utm, str) or to_utm == True:
182
+ if isinstance(to_utm, str) or to_utm:
183
183
  apply_utm = True
184
184
  check_import_utm()
185
185
  utmz = int(to_utm[:-1]) if isinstance(to_utm, str) else None
@@ -190,7 +190,7 @@ def read_shp_polygons(
190
190
  names = pnames if names is None else names
191
191
  for name in names:
192
192
  if name == name: # exclude nan values
193
- if not name in pnames:
193
+ if name not in pnames:
194
194
  raise KeyError(
195
195
  f"Name '{name}' not found in file '{fname}'. Names: {pnames}"
196
196
  )
@@ -106,9 +106,10 @@ class PandasFileHelper:
106
106
  elif sfx == "h5":
107
107
  f = pd.read_hdf
108
108
  elif sfx == "nc":
109
- f = lambda fname, **pars: xarray.open_dataset(
110
- fname, **pars
111
- ).to_dataframe()
109
+
110
+ def f(fname, **pars):
111
+ """little helper to read netcdf files"""
112
+ return xarray.open_dataset(fname, **pars).to_dataframe()
112
113
 
113
114
  if f is not None:
114
115
  pars = deepcopy(cls.DEFAULT_READING_PARAMETERS[fmt])
foxes/utils/tab_files.py CHANGED
@@ -63,7 +63,6 @@ def read_tab_file(fname, normalize=True):
63
63
 
64
64
 
65
65
  if __name__ == "__main__":
66
-
67
66
  import argparse
68
67
 
69
68
  parser = argparse.ArgumentParser()
foxes/utils/weibull.py ADDED
@@ -0,0 +1,28 @@
1
+ import numpy as np
2
+
3
+
4
+ def weibull_weights(ws, ws_deltas, A, k):
5
+ """
6
+ Computes the weibull weights for given wind speeds
7
+
8
+ Parameters
9
+ ----------
10
+ ws: numpy.ndarray
11
+ The wind speed bin centre values
12
+ ws_deltas: numpy.ndarray
13
+ The wind speed bin widths, same shape as ws
14
+ A: numpy.ndarray
15
+ The Weibull scale parameters, same shape as ws
16
+ k: numpy.ndarray
17
+ The Weibull shape parameters, same shape as ws
18
+
19
+ Returns
20
+ -------
21
+ weights: numpy.ndarray
22
+ The weights, same shape as ws
23
+
24
+ :group: utils
25
+
26
+ """
27
+ wsA = ws / A
28
+ return ws_deltas * (k / A * wsA ** (k - 1) * np.exp(-(wsA**k)))
foxes/utils/wrg_utils.py CHANGED
@@ -42,7 +42,9 @@ class ReaderWRG:
42
42
  int(self._res),
43
43
  )
44
44
 
45
- cols_sel = lambda name, secs: [f"{name}_{i}" for i in range(secs)]
45
+ def cols_sel(name, secs):
46
+ """little helper to create column names"""
47
+ return [f"{name}_{i}" for i in range(secs)]
46
48
 
47
49
  cols = [0] * (8 + 3 * self._n_sectors)
48
50
  cols[0] = "utmx"
@@ -1,3 +1,5 @@
1
+ import numpy as np
2
+ from xarray import Dataset
1
3
  from pathlib import Path
2
4
 
3
5
  from foxes.variables import get_default_digits
@@ -31,18 +33,23 @@ def write_nc(
31
33
  """
32
34
  fpath = Path(fpath)
33
35
  if round is not None:
36
+ crds = {}
34
37
  for v in ds.coords.keys():
35
38
  d = round.get(v, get_default_digits(v))
36
39
  if d is not None:
37
40
  if verbosity > 1:
38
41
  print(f"File {fpath.name}: Rounding {v} to {d} decimals")
39
- ds[v].data = ds[v].data.round(decimals=d)
42
+ crds[v] = np.round(ds[v].to_numpy(), d)
43
+ else:
44
+ crds[v] = ds[v].to_numpy()
45
+ dvrs = {}
40
46
  for v in ds.data_vars.keys():
41
47
  d = round.get(v, get_default_digits(v))
42
48
  if d is not None:
43
49
  if verbosity > 1:
44
50
  print(f"File {fpath.name}: Rounding {v} to {d} decimals")
45
- ds[v].data = ds[v].data.round(decimals=d)
51
+ dvrs[v] = (ds[v].dims, np.round(ds[v].to_numpy(), d))
52
+ ds = Dataset(coords=crds, data_vars=dvrs)
46
53
 
47
54
  enc = None
48
55
  if complevel is not None and complevel > 0:
foxes/variables.py CHANGED
@@ -54,6 +54,21 @@ WD = "WD"
54
54
  :group: foxes.variables
55
55
  """
56
56
 
57
+ UV = "UV"
58
+ """ The 2D wind vector in m/s
59
+ :group: foxes.variables
60
+ """
61
+
62
+ U = "U"
63
+ """ The first horizontal wind vector component in m/s
64
+ :group: foxes.variables
65
+ """
66
+
67
+ V = "V"
68
+ """ The second horizontal wind vector component in m/s
69
+ :group: foxes.variables
70
+ """
71
+
57
72
  TI = "TI"
58
73
  """ The turbulence intensity
59
74
  :group: foxes.variables
@@ -128,6 +143,17 @@ calculated from third moment
128
143
  """
129
144
 
130
145
 
146
+ WEIBULL_A = "Weibull_A"
147
+ """ The Weibull scale parameter,
148
+ :group: foxes.variables
149
+ """
150
+
151
+ WEIBULL_k = "Weibull_k"
152
+ """ The Weibull shape parameter,
153
+ :group: foxes.variables
154
+ """
155
+
156
+
131
157
  AMB_WS = "AMB_WS"
132
158
  """ The ambient wind speed in m/s
133
159
  :group: foxes.variables
@@ -138,6 +164,21 @@ AMB_WD = "AMB_WD"
138
164
  :group: foxes.variables
139
165
  """
140
166
 
167
+ AMB_UV = "AMB_UV"
168
+ """ The ambient 2D wind vector in m/s
169
+ :group: foxes.variables
170
+ """
171
+
172
+ AMB_U = "AMB_U"
173
+ """ The first horizontal ambient wind vector component in m/s
174
+ :group: foxes.variables
175
+ """
176
+
177
+ AMB_V = "AMB_V"
178
+ """ The second horizontal ambient wind vector component in m/s
179
+ :group: foxes.variables
180
+ """
181
+
141
182
  AMB_TI = "AMB_TI"
142
183
  """ The ambient turbulence intensity
143
184
  :group: foxes.variables
@@ -203,6 +244,16 @@ calculated from third moment
203
244
  :group: foxes.variables
204
245
  """
205
246
 
247
+ AMB_WEIBULL_A = "AMB_Weibull_A"
248
+ """ Ambient Weibull scale parameter,
249
+ :group: foxes.variables
250
+ """
251
+
252
+ AMB_WEIBULL_k = "AMB_Weibull_k"
253
+ """ Ambient Weibull shape parameter,
254
+ :group: foxes.variables
255
+ """
256
+
206
257
 
207
258
  var2amb = {
208
259
  v: f"AMB_{v}"
@@ -219,8 +270,13 @@ var2amb = {
219
270
  REWS,
220
271
  REWS2,
221
272
  REWS3,
273
+ WEIBULL_A,
274
+ WEIBULL_k,
222
275
  YLD,
223
276
  CAP,
277
+ UV,
278
+ U,
279
+ V,
224
280
  ]
225
281
  }
226
282
  """ Mapping from variable to the corresponding
@@ -282,9 +338,10 @@ PA_BETA = "PA_beta"
282
338
  :group: foxes.variables
283
339
  """
284
340
 
285
- DEFAULT_DIGITS = {
341
+ DEFAULT_DIGITS = 4
342
+
343
+ ROUND_DIGITS = {
286
344
  WD: 3,
287
- WS: 4,
288
345
  TI: 6,
289
346
  RHO: 5,
290
347
  P: 3,
@@ -293,10 +350,14 @@ DEFAULT_DIGITS = {
293
350
  YLD: 3,
294
351
  CAP: 5,
295
352
  EFF: 5,
353
+ WEIBULL_A: 3,
354
+ WEIBULL_k: 3,
355
+ YAW: 3,
356
+ YAWM: 3,
296
357
  }
297
- """ The default output digits
298
- :group: foxes.variables
299
- """
358
+ ROUND_DIGITS.update(
359
+ {var2amb[v]: ROUND_DIGITS[v] for v in var2amb.keys() if v in ROUND_DIGITS}
360
+ )
300
361
 
301
362
 
302
363
  def get_default_digits(variable):
@@ -314,7 +375,4 @@ def get_default_digits(variable):
314
375
  The default number of output digits
315
376
 
316
377
  """
317
- v = amb2var.get(variable, variable)
318
- if v in [REWS, REWS2, REWS3]:
319
- v = WS
320
- return DEFAULT_DIGITS.get(v, None)
378
+ return ROUND_DIGITS.get(variable, DEFAULT_DIGITS)
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: foxes
3
- Version: 1.2.5
3
+ Version: 1.4
4
4
  Summary: Farm Optimization and eXtended yield Evaluation Software
5
5
  Author: Jonas Schulte
6
6
  Maintainer: Jonas Schulte
@@ -56,16 +56,15 @@ Requires-Dist: scipy
56
56
  Requires-Dist: cycler
57
57
  Requires-Dist: tqdm
58
58
  Requires-Dist: pyyaml
59
+ Requires-Dist: h5netcdf
59
60
  Provides-Extra: opt
60
61
  Requires-Dist: foxes-opt; extra == "opt"
61
62
  Provides-Extra: dask
62
- Requires-Dist: h5netcdf; extra == "dask"
63
63
  Requires-Dist: dask; extra == "dask"
64
64
  Requires-Dist: distributed; extra == "dask"
65
65
  Requires-Dist: dask-jobqueue; extra == "dask"
66
66
  Requires-Dist: setuptools; extra == "dask"
67
67
  Provides-Extra: eng
68
- Requires-Dist: h5netcdf; extra == "eng"
69
68
  Requires-Dist: multiprocess; extra == "eng"
70
69
  Requires-Dist: dask; extra == "eng"
71
70
  Requires-Dist: distributed; extra == "eng"
@@ -74,7 +73,6 @@ Requires-Dist: setuptools; extra == "eng"
74
73
  Requires-Dist: mpi4py; extra == "eng"
75
74
  Requires-Dist: ray; extra == "eng"
76
75
  Provides-Extra: eng0
77
- Requires-Dist: h5netcdf; extra == "eng0"
78
76
  Requires-Dist: multiprocess; extra == "eng0"
79
77
  Requires-Dist: dask; extra == "eng0"
80
78
  Requires-Dist: distributed; extra == "eng0"
@@ -84,7 +82,6 @@ Requires-Dist: ray; extra == "eng0"
84
82
  Provides-Extra: test
85
83
  Requires-Dist: flake8; extra == "test"
86
84
  Requires-Dist: pytest; extra == "test"
87
- Requires-Dist: h5netcdf; extra == "test"
88
85
  Provides-Extra: doc
89
86
  Requires-Dist: setuptools; extra == "doc"
90
87
  Requires-Dist: sphinx; extra == "doc"
@@ -101,7 +98,8 @@ Requires-Dist: flake8; extra == "dev"
101
98
  Requires-Dist: pytest; extra == "dev"
102
99
  Requires-Dist: jupyter; extra == "dev"
103
100
  Requires-Dist: objsize; extra == "dev"
104
- Requires-Dist: black[jupyter]; extra == "dev"
101
+ Requires-Dist: ruff; extra == "dev"
102
+ Dynamic: license-file
105
103
 
106
104
  # Welcome to foxes
107
105
 
@@ -161,14 +159,7 @@ Evaluation Software"`
161
159
 
162
160
  ## Requirements
163
161
 
164
- The supported Python versions are:
165
-
166
- - `Python 3.8`
167
- - `Python 3.9`
168
- - `Python 3.10`
169
- - `Python 3.11`
170
- - `Python 3.12`
171
- - `Python 3.13`
162
+ The supported Python versions are `Python 3.8`...`3.13`.
172
163
 
173
164
  ## Installation
174
165
 
@@ -191,15 +182,17 @@ For detailed examples of how to run _foxes_, check the `examples` and `notebooks
191
182
  ```python
192
183
  import foxes
193
184
 
194
- states = foxes.input.states.Timeseries("timeseries_3000.csv.gz", ["WS", "WD","TI","RHO"])
185
+ if __name__ == "__main__":
186
+
187
+ states = foxes.input.states.Timeseries("timeseries_3000.csv.gz", ["WS", "WD","TI","RHO"])
195
188
 
196
- farm = foxes.WindFarm()
197
- foxes.input.farm_layout.add_from_file(farm, "test_farm_67.csv", turbine_models=["NREL5MW"])
189
+ farm = foxes.WindFarm()
190
+ foxes.input.farm_layout.add_from_file(farm, "test_farm_67.csv", turbine_models=["NREL5MW"])
198
191
 
199
- algo = foxes.algorithms.Downwind(farm, states, ["Jensen_linear_k007"])
200
- farm_results = algo.calc_farm()
192
+ algo = foxes.algorithms.Downwind(farm, states, ["Jensen_linear_k007"])
193
+ farm_results = algo.calc_farm()
201
194
 
202
- print(farm_results)
195
+ print(farm_results)
203
196
  ```
204
197
 
205
198
  ## Testing