Skip to content

Commit

Permalink
Increase tolerance
Browse files Browse the repository at this point in the history
  • Loading branch information
birgits committed Oct 29, 2018
1 parent 3afa3b3 commit df6dd5b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion edisgo/grid/network.py
Original file line number Diff line number Diff line change
Expand Up @@ -1686,7 +1686,7 @@ def _precheck(self, curtailment_timeseries, feedin_df, curtailment_key):
feedin_selected_sum = feedin_df.sum(axis=1)
diff = feedin_selected_sum - curtailment_timeseries
# add tolerance (set small negative values to zero)
diff[diff.between(-1e-1, 0)] = 0
diff[diff.between(-1, 0)] = 0
if not (diff >= 0).all():
bad_time_steps = [_ for _ in diff.index
if diff[_] < 0]
Expand Down

0 comments on commit df6dd5b

Please sign in to comment.