diff --git a/CaseStudy.py b/CaseStudy.py index c13b6e8..8aeff8a 100644 --- a/CaseStudy.py +++ b/CaseStudy.py @@ -1209,7 +1209,7 @@ def _resample_hindex_from_target_probs(self, target_probs: dict[str, np.ndarray] for scenario in hindex_flat['scenario'].unique().tolist(): sc = hindex_flat[hindex_flat['scenario'] == scenario].copy() sc = sc.sort_values(['p']) - n_ks_per_rp = len(self.dPower_WeightsK['scenario'] == scenario) + n_ks_per_rp = int((self.dPower_WeightsK['scenario'] == scenario).sum()) period_labels = sc['p'].tolist() first_rp = sc['rp'].iloc[0]