Skip to content

Commit

Permalink
feat: only scale factors that deviate significantly from 1.0 considered
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Muldrew committed May 1, 2020
1 parent 8521f29 commit d5692ce
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions powersimdata/design/clean_capacity_scaling.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ def output_capacities_table(self, base_grid=None):
next_capacities = self.data_frame_of_next_capacities()[[
'next_solar_capacity', 'next_wind_capacity']]
if base_grid is None:
base_grid = Grid([self.interconnect])
base_grid = Grid(self.interconnect)
grid_info = GridInfo(base_grid)
grid_resources = grid_info.get_available_resource('all')
gen_capacity = pd.DataFrame(
Expand Down Expand Up @@ -169,8 +169,9 @@ def create_scale_factor_table(self, base_grid=None, gen_capacity=None):
f"{load_zone} and resource {res} and cannot be "
f"scaled!")
else:
scale_factor_table[res][load_zone] = \
row[res]/base_target_resource_cap
scale_factor = row[res] / base_target_resource_cap
if abs(scale_factor - 1.0) > 0.001:
scale_factor_table[res][load_zone] = scale_factor
return scale_factor_table

def create_change_table(self, scale_factor_table=None):
Expand Down

0 comments on commit d5692ce

Please sign in to comment.