Skip to content

Commit 4fa88a6

Browse files
committed
Round values in total_capacity check
1 parent cc0c880 commit 4fa88a6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

windpowerlib/wind_farm.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,9 @@ def check_and_complete_wind_turbine_fleet(self):
177177
'wind turbine is set.'.format(
178178
turbine=row['wind_turbine']))
179179
else:
180-
if not row['total_capacity'] == (
180+
if not round(row['total_capacity'], 3) == round(
181181
row['number_of_turbines'] *
182-
row['wind_turbine'].nominal_power):
182+
row['wind_turbine'].nominal_power, 3):
183183
self.wind_turbine_fleet.loc[ix, 'total_capacity'] = \
184184
row['number_of_turbines'] * \
185185
row['wind_turbine'].nominal_power

0 commit comments

Comments
 (0)