Hack reduce_time_domain to not always cluster time
If settings parameter reduce_time_domain is not True, return the full
time series of load and gen variability.
@@ -163,6 +163,7 @@ def reduce_time_domain(
demand_segments = load_demand_segments(settings)
+ if settings["reduce_time_domain"]:
days = settings["time_domain_days_per_period"]
time_periods = settings["time_domain_periods"]
include_peak_day = settings["include_peak_day"]
@@ -183,7 +184,8 @@ def reduce_time_domain(
time_index = pd.Series(data=reduced_load_profile.index + 1, name="Time_index")
sub_weights = pd.Series(
- data=[x * (days * 24) for x in results["ClusterWeights"]], name="Sub_Weights"
+ data=[x * (days * 24) for x in results["ClusterWeights"]],
+ name="Sub_Weights",
)
hours_per_period = pd.Series(data=[days * 24], name="Hours_per_period")
subperiods = pd.Series(data=[time_periods], name="Subperiods")
@@ -200,3 +202,24 @@ def reduce_time_domain(
)
return reduced_resource_profile, reduced_load_output
+
+ else:
+ time_index = pd.Series(data=range(1, len(load_profiles + 1)), name="Time_index")
+ sub_weights = pd.Series(data=[1], name="Sub_Weights")
+ hours_per_period = pd.Series(data=[168], name="Hours_per_period")
+ subperiods = pd.Series(data=[1], name="Subperiods")
+
+ # Not actually reduced
+ load_output = pd.concat(
+ [
+ demand_segments,
+ subperiods,
+ hours_per_period,
+ sub_weights,
+ time_index,
+ load_profiles,
+ ],
+ axis=1,
+ )
+
+ return resource_profiles, load_output
