Skip to content

Commit ff5c4aa

Browse files
committed
Rename time series to feedin_power_plant
1 parent 5b9e936 commit ff5c4aa

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

tests/test_modelchain.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def test_run_model(self):
190190

191191
# Test with default parameters of modelchain (power curve)
192192
power_output_exp = pd.Series(data=[1731887.39768, 3820152.27489],
193-
name='feedin')
193+
name='feedin_power_plant')
194194
test_mc = mc.ModelChain(wt.WindTurbine(**test_turbine))
195195
test_mc.run_model(weather_df)
196196
assert_series_equal(test_mc.power_output, power_output_exp)
@@ -200,15 +200,15 @@ def test_run_model(self):
200200
'power_output_model': 'power_curve',
201201
'density_correction': True}
202202
power_output_exp = pd.Series(data=[1433937.37959, 3285183.55084],
203-
name='feedin')
203+
name='feedin_power_plant')
204204
test_mc = mc.ModelChain(wt.WindTurbine(**test_turbine),
205205
**test_modelchain)
206206
test_mc.run_model(weather_df)
207207
assert_series_equal(test_mc.power_output, power_output_exp)
208208

209209
# Test with power coefficient curve and hellman
210210
power_output_exp = pd.Series(data=[559060.36156, 1251143.98621],
211-
name='feedin')
211+
name='feedin_power_plant')
212212
test_turbine['fetch_curve'] = 'power_coefficient_curve'
213213
test_modelchain = {'wind_speed_model': 'hellman',
214214
'power_output_model': 'power_coefficient_curve',

tests/test_power_output.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def test_power_coefficient_curve(self):
2323
# Test wind_speed as pd.Series with density and power_coefficient_curve
2424
# as pd.Series and np.array
2525
power_output_exp = pd.Series(data=[0.0, 244615.399, 0.0],
26-
name='feedin')
26+
name='feedin_power_plant')
2727
assert_series_equal(power_coefficient_curve(**parameters),
2828
power_output_exp)
2929
parameters['density'] = np.array(parameters['density'])
@@ -68,7 +68,7 @@ def test_power_curve(self):
6868
# Test wind_speed as pd.Series and power_curve as pd.Series and
6969
# np.array
7070
power_output_exp = pd.Series(data=[0.0, 450.0, 0.0],
71-
name='feedin')
71+
name='feedin_power_plant')
7272
assert_series_equal(power_curve(**parameters), power_output_exp)
7373
parameters['power_curve_values'] = np.array(
7474
parameters['power_curve_values'])
@@ -109,7 +109,7 @@ def test_power_curve(self):
109109
# Test wind_speed as pd.Series with density and power_curve as
110110
# np. array and pd.Series
111111
power_output_exp = pd.Series(data=[0.0, 461.00290572, 0.0],
112-
name='feedin')
112+
name='feedin_power_plant')
113113
parameters['wind_speed'] = pd.Series(data=parameters['wind_speed'])
114114
assert_series_equal(power_curve(**parameters), power_output_exp)
115115
parameters['density'] = pd.Series(data=parameters['density'])
@@ -139,7 +139,7 @@ def test_power_curve_density_correction(self):
139139
# Test wind_speed as pd.Series with density and power_curve as
140140
# pd.Series and np.array
141141
power_output_exp = pd.Series(data=[0.0, 461.00290572, 0.0],
142-
name='feedin')
142+
name='feedin_power_plant')
143143
assert_series_equal(power_curve_density_correction(**parameters),
144144
power_output_exp)
145145
parameters['density'] = np.array(parameters['density'])

windpowerlib/power_output.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ def power_curve(wind_speed, power_curve_wind_speeds, power_curve_values,
127127
# Power_output as pd.Series if wind_speed is pd.Series (else: np.array)
128128
if isinstance(wind_speed, pd.Series):
129129
power_output = pd.Series(data=power_output, index=wind_speed.index,
130-
name='feedin')
130+
name='feedin_power_plant')
131131
else:
132132
power_output = np.array(power_output)
133133
elif density_correction is True:
@@ -220,7 +220,7 @@ def power_curve_density_correction(wind_speed, power_curve_wind_speeds,
220220
# Power_output as pd.Series if wind_speed is pd.Series (else: np.array)
221221
if isinstance(wind_speed, pd.Series):
222222
power_output = pd.Series(data=power_output, index=wind_speed.index,
223-
name='feedin')
223+
name='feedin_power_plant')
224224
else:
225225
power_output = np.array(power_output)
226226
return power_output

0 commit comments

Comments
 (0)