Skip to content

Commit 9848ee2

Browse files
committed
Merge branch 'dev' into features/wind_farms_and_clusters
2 parents cd1f0c9 + a3d3f2c commit 9848ee2

File tree

4 files changed

+12
-9
lines changed

4 files changed

+12
-9
lines changed

doc/requirements.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
sphinx>=1.4
22
ipykernel
3-
nbsphinx
3+
nbsphinx
4+
pandas
5+
numpy

example/basic_example.ipynb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@
177177
"# specification of own wind turbine (Note: power coefficient values and\n",
178178
"# nominal power have to be in Watt)\n",
179179
"myTurbine = {\n",
180-
" 'turbine_name': 'myTurbine',\n",
180+
" 'object_name': 'myTurbine',\n",
181181
" 'nominal_power': 3e6, # in W\n",
182182
" 'hub_height': 105, # in m\n",
183183
" 'rotor_diameter': 90, # in m\n",
@@ -202,7 +202,7 @@
202202
"# if you want to use the power coefficient curve change the value of\n",
203203
"# 'fetch_curve' to 'power_coefficient_curve'\n",
204204
"enerconE126 = {\n",
205-
" 'turbine_name': 'ENERCON E 126 7500', # turbine name as in register\n",
205+
" 'object_name': 'ENERCON E 126 7500', # turbine name as in register\n",
206206
" 'hub_height': 135, # in m\n",
207207
" 'rotor_diameter': 127, # in m\n",
208208
" 'fetch_curve': 'power_curve' # fetch power curve\n",
@@ -357,7 +357,7 @@
357357
"name": "python",
358358
"nbconvert_exporter": "python",
359359
"pygments_lexer": "ipython3",
360-
"version": "3.4.2"
360+
"version": "3.5.3"
361361
}
362362
},
363363
"nbformat": 4,

windpowerlib/modelchain.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
__license__ = "GPLv3"
1010

1111
import logging
12-
from . import wind_speed, density, temperature, power_output, tools
12+
from windpowerlib import wind_speed, density, temperature, power_output, tools
1313

1414

1515
class ModelChain(object):
@@ -88,7 +88,8 @@ class ModelChain(object):
8888
>>> enerconE126 = {
8989
... 'hub_height': 135,
9090
... 'rotor_diameter': 127,
91-
... 'object_name': 'ENERCON E 126 7500'}
91+
... 'object_name': 'ENERCON E 126 7500',
92+
... 'fetch_curve': 'power_curve'}
9293
>>> e126 = wind_turbine.WindTurbine(**enerconE126)
9394
>>> modelchain_data = {'density_model': 'ideal_gas'}
9495
>>> e126_mc = modelchain.ModelChain(e126, **modelchain_data)

windpowerlib/tools.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,9 @@ def linear_interpolation_extrapolation(df, target_height):
5959
... columns=[np.array(['wind_speed',
6060
... 'wind_speed']),
6161
... np.array([10, 80])])
62-
>>> linear_interpolation_extrapolation(
63-
... weather_df['wind_speed'], 100)[0]
64-
6.8571428571428577
62+
>>> round(linear_interpolation_extrapolation(
63+
... weather_df['wind_speed'], 100)[0], 10)
64+
6.8571428571
6565
6666
"""
6767
# find closest heights

0 commit comments

Comments
 (0)