SYMBOL INDEX (433 symbols across 53 files) FILE: benchmarks/bench.py function _run (line 47) | def _run(case) -> None: function test_bench (line 62) | def test_bench(case, benchmark): FILE: benchmarks/benchmark_tuning.py function main (line 27) | def main() -> None: FILE: src/tsam/__init__.py function __getattr__ (line 47) | def __getattr__(name: str): FILE: src/tsam/api.py function _weighted_mean (line 28) | def _weighted_mean( function _weighted_rms (line 53) | def _weighted_rms( function _parse_duration_hours (line 83) | def _parse_duration_hours(value: int | float | str, param_name: str) -> ... function aggregate (line 109) | def aggregate( function _build_clustering_result (line 426) | def _build_clustering_result( function _apply_representation_params (line 530) | def _apply_representation_params( function _build_old_params (line 569) | def _build_old_params( function unstack_to_periods (line 678) | def unstack_to_periods( FILE: src/tsam/config.py class Distribution (line 44) | class Distribution: method to_dict (line 60) | def to_dict(self) -> dict[str, Any]: method from_dict (line 70) | def from_dict(cls, data: dict) -> Distribution: class MinMaxMean (line 79) | class MinMaxMean: method to_dict (line 95) | def to_dict(self) -> dict[str, Any]: method from_dict (line 105) | def from_dict(cls, data: dict) -> MinMaxMean: function _resolve_representation (line 117) | def _resolve_representation(rep: Representation) -> Representation: function _representation_to_dict (line 136) | def _representation_to_dict(rep: Representation) -> str | dict[str, Any]: function _representation_from_dict (line 143) | def _representation_from_dict(data: str | dict) -> Representation: function _time_index_to_dict (line 156) | def _time_index_to_dict(idx: pd.DatetimeIndex) -> dict[str, Any] | list[... function _time_index_from_dict (line 168) | def _time_index_from_dict( class ClusterConfig (line 178) | class ClusterConfig: method __post_init__ (line 248) | def __post_init__(self) -> None: method get_representation (line 258) | def get_representation(self) -> Representation: method to_dict (line 274) | def to_dict(self) -> dict[str, Any]: method from_dict (line 292) | def from_dict(cls, data: dict) -> ClusterConfig: class SegmentConfig (line 310) | class SegmentConfig: method __post_init__ (line 336) | def __post_init__(self) -> None: method to_dict (line 342) | def to_dict(self) -> dict[str, Any]: method from_dict (line 350) | def from_dict(cls, data: dict) -> SegmentConfig: function _validate_disaggregate_input (line 359) | def _validate_disaggregate_input( function _expand_segments_to_timesteps (line 423) | def _expand_segments_to_timesteps( function _expand_periods (line 470) | def _expand_periods( class ClusteringResult (line 502) | class ClusteringResult: method __post_init__ (line 608) | def __post_init__(self) -> None: method n_clusters (line 623) | def n_clusters(self) -> int: method n_original_periods (line 628) | def n_original_periods(self) -> int: method n_segments (line 633) | def n_segments(self) -> int | None: method __repr__ (line 639) | def __repr__(self) -> str: method to_dataframe (line 664) | def to_dataframe(self) -> pd.DataFrame: method segment_dataframe (line 688) | def segment_dataframe(self) -> pd.DataFrame | None: method to_dict (line 712) | def to_dict(self) -> dict[str, Any]: method from_dict (line 754) | def from_dict(cls, data: dict) -> ClusteringResult: method to_json (line 800) | def to_json(self, path: str) -> None: method from_json (line 839) | def from_json(cls, path: str) -> ClusteringResult: method disaggregate (line 862) | def disaggregate(self, data: pd.DataFrame) -> pd.DataFrame: method apply (line 929) | def apply( class ExtremeConfig (line 1164) | class ExtremeConfig: method has_extremes (line 1203) | def has_extremes(self) -> bool: method to_dict (line 1209) | def to_dict(self) -> dict[str, Any]: method from_dict (line 1225) | def from_dict(cls, data: dict) -> ExtremeConfig: FILE: src/tsam/exceptions.py class LegacyAPIWarning (line 4) | class LegacyAPIWarning(FutureWarning): FILE: src/tsam/hyperparametertuning.py function getNoPeriodsForDataReduction (line 11) | def getNoPeriodsForDataReduction(noRawTimeSteps, segmentsPerPeriod, data... function getNoSegmentsForDataReduction (line 38) | def getNoSegmentsForDataReduction(noRawTimeSteps, typicalPeriods, dataRe... class HyperTunedAggregations (line 65) | class HyperTunedAggregations: method __init__ (line 66) | def __init__(self, base_aggregation, saveAggregationHistory=True): method _testAggregation (line 106) | def _testAggregation(self, noTypicalPeriods, noSegments): method _deleteTestHistory (line 131) | def _deleteTestHistory(self, index): method identifyOptimalSegmentPeriodCombination (line 142) | def identifyOptimalSegmentPeriodCombination(self, dataReduction): method identifyParetoOptimalAggregation (line 212) | def identifyParetoOptimalAggregation(self, untilTotalTimeSteps=None): FILE: src/tsam/periodAggregation.py function aggregatePeriods (line 6) | def aggregatePeriods( FILE: src/tsam/plot.py function _validate_columns (line 45) | def _validate_columns( function _duration_curve_figure (line 94) | def _duration_curve_figure( class ResultPlotAccessor (line 125) | class ResultPlotAccessor: method __init__ (line 140) | def __init__(self, result: AggregationResult): method cluster_representatives (line 143) | def cluster_representatives( method cluster_members (line 193) | def cluster_members( method cluster_weights (line 448) | def cluster_weights(self, title: str = "Cluster Weights") -> go.Figure: method accuracy (line 482) | def accuracy(self, title: str = "Accuracy Metrics") -> go.Figure: method segment_durations (line 522) | def segment_durations(self, title: str = "Segment Durations") -> go.Fi... method compare (line 581) | def compare( method residuals (line 666) | def residuals( FILE: src/tsam/representations.py function representations (line 7) | def representations( function maxoidRepresentation (line 58) | def maxoidRepresentation(candidates, clusterOrder): function medoidRepresentation (line 83) | def medoidRepresentation(candidates, clusterOrder): function meanRepresentation (line 108) | def meanRepresentation(candidates, clusterOrder): function minmaxmeanRepresentation (line 129) | def minmaxmeanRepresentation( FILE: src/tsam/result.py class AccuracyMetrics (line 19) | class AccuracyMetrics: method summary (line 63) | def summary(self) -> pd.DataFrame: method __repr__ (line 83) | def __repr__(self) -> str: class AggregationResult (line 100) | class AggregationResult: method n_clusters (line 176) | def n_clusters(self) -> int: method n_segments (line 186) | def n_segments(self) -> int | None: method cluster_assignments (line 191) | def cluster_assignments(self) -> np.ndarray: method __repr__ (line 199) | def __repr__(self) -> str: method original (line 211) | def original(self) -> pd.DataFrame: method reconstructed (line 228) | def reconstructed(self) -> pd.DataFrame: method disaggregate (line 247) | def disaggregate(self, data: pd.DataFrame) -> pd.DataFrame: method residuals (line 280) | def residuals(self) -> pd.DataFrame: method to_dict (line 297) | def to_dict(self) -> dict: method timestep_index (line 327) | def timestep_index(self) -> list[int]: method period_index (line 340) | def period_index(self) -> list[int]: method assignments (line 354) | def assignments(self) -> pd.DataFrame: method plot (line 430) | def plot(self) -> ResultPlotAccessor: FILE: src/tsam/timeseriesaggregation.py function unstackToPeriods (line 27) | def unstackToPeriods(timeSeries, timeStepsPerPeriod): class TimeSeriesAggregation (line 88) | class TimeSeriesAggregation: method __init__ (line 119) | def __init__( method _check_init_args (line 376) | def _check_init_args(self): method _normalizeTimeSeries (line 575) | def _normalizeTimeSeries(self, sameMean=False): method _unnormalizeTimeSeries (line 598) | def _unnormalizeTimeSeries(self, normalizedTimeSeries, sameMean=False): method _preProcessTimeSeries (line 627) | def _preProcessTimeSeries(self): method _postProcessTimeSeries (line 665) | def _postProcessTimeSeries(self, normalizedTimeSeries, applyWeighting=... method _addExtremePeriods (line 686) | def _addExtremePeriods( method _append_col_with (line 877) | def _append_col_with(self, column, append_with=" max."): method _rescaleClusterPeriods (line 887) | def _rescaleClusterPeriods(self, clusterOrder, clusterPeriods, extreme... method _clusterSortedPeriods (line 986) | def _clusterSortedPeriods( method createTypicalPeriods (line 1057) | def createTypicalPeriods(self): method prepareEnersysInput (line 1244) | def prepareEnersysInput(self): method stepIdx (line 1256) | def stepIdx(self): method clusterPeriodIdx (line 1266) | def clusterPeriodIdx(self): method clusterOrder (line 1275) | def clusterOrder(self): method clusterPeriodNoOccur (line 1285) | def clusterPeriodNoOccur(self): method clusterPeriodDict (line 1294) | def clusterPeriodDict(self): method segmentDurationDict (line 1307) | def segmentDurationDict(self): method predictOriginalData (line 1334) | def predictOriginalData(self): method indexMatching (line 1381) | def indexMatching(self): method accuracyIndicators (line 1428) | def accuracyIndicators(self): method totalAccuracyIndicators (line 1462) | def totalAccuracyIndicators(self): FILE: src/tsam/tuning.py class _AggregateOpts (line 36) | class _AggregateOpts(TypedDict): function _test_single_config_file (line 53) | def _test_single_config_file( function _infer_temporal_resolution (line 112) | def _infer_temporal_resolution(data: pd.DataFrame) -> float: function _parallel_context (line 131) | def _parallel_context( function _test_configs (line 168) | def _test_configs( function _get_n_workers (line 250) | def _get_n_workers(n_jobs: int | None) -> int: class TuningResult (line 271) | class TuningResult: method summary (line 309) | def summary(self) -> pd.DataFrame: method find_by_timesteps (line 316) | def find_by_timesteps(self, target: int) -> AggregationResult: method find_by_rmse (line 342) | def find_by_rmse(self, threshold: float) -> AggregationResult: method plot (line 374) | def plot(self, show_labels: bool = True, **kwargs: object) -> object: method __len__ (line 406) | def __len__(self) -> int: method __getitem__ (line 409) | def __getitem__(self, index: int) -> AggregationResult: method __iter__ (line 412) | def __iter__(self): function find_clusters_for_reduction (line 416) | def find_clusters_for_reduction( function find_segments_for_reduction (line 445) | def find_segments_for_reduction( function find_optimal_combination (line 474) | def find_optimal_combination( function find_pareto_front (line 658) | def find_pareto_front( function _find_pareto_front_targeted (line 814) | def _find_pareto_front_targeted( function _find_pareto_front_steepest (line 909) | def _find_pareto_front_steepest( FILE: src/tsam/utils/durationRepresentation.py function durationRepresentation (line 9) | def durationRepresentation( function _representMinMax (line 151) | def _representMinMax( FILE: src/tsam/utils/k_maxoids.py class KMaxoids (line 10) | class KMaxoids(BaseEstimator, ClusterMixin, TransformerMixin): method __init__ (line 21) | def __init__( method _check_init_args (line 30) | def _check_init_args(self): method fit (line 54) | def fit(self, X, y=None): method _check_array (line 77) | def _check_array(self, X): method k_maxoids (line 92) | def k_maxoids(self, X, k, numpasses=5, doLogarithmic=False, n_init=100): FILE: src/tsam/utils/k_medoids_contiguity.py function k_medoids_contiguity (line 20) | def k_medoids_contiguity( function _contiguity_to_graph (line 115) | def _contiguity_to_graph(adjacency, distances=None): FILE: src/tsam/utils/k_medoids_exact.py class KMedoids (line 15) | class KMedoids(BaseEstimator, ClusterMixin, TransformerMixin): method __init__ (line 35) | def __init__( method _check_init_args (line 53) | def _check_init_args(self): method fit (line 77) | def fit(self, X, y=None): method _check_array (line 117) | def _check_array(self, X): method _k_medoids_exact (line 132) | def _k_medoids_exact(self, distances, n_clusters): function _setup_k_medoids (line 151) | def _setup_k_medoids(distances, n_clusters): function _solve_given_pyomo_model (line 205) | def _solve_given_pyomo_model(M, solver="highs"): FILE: src/tsam/utils/segmentation.py function segmentation (line 8) | def segmentation( FILE: test/_configs.py function _make_constant (line 37) | def _make_constant() -> pd.DataFrame: function _make_with_zero_column (line 43) | def _make_with_zero_column() -> pd.DataFrame: function get_data (line 60) | def get_data(name: str, max_timesteps: int | None = None) -> pd.DataFrame: class BaseConfig (line 83) | class BaseConfig: class OldCase (line 743) | class OldCase: function build_old_cases (line 753) | def build_old_cases(configs: list[BaseConfig] | None = None) -> list[Old... function case_ids (line 779) | def case_ids(cases: list) -> list[str]: FILE: test/_old_new_equivalence.py class EquivalenceCase (line 469) | class EquivalenceCase: function _build_cases (line 481) | def _build_cases() -> list[EquivalenceCase]: function _run_old (line 518) | def _run_old(data: pd.DataFrame, case: EquivalenceCase): function _run_new (line 529) | def _run_new(data: pd.DataFrame, case: EquivalenceCase): function _suppress_windows_kmeans_warnings (line 537) | def _suppress_windows_kmeans_warnings(case: EquivalenceCase): class TestOldNewEquivalence (line 565) | class TestOldNewEquivalence: method test_cluster_representatives (line 569) | def test_cluster_representatives(self, case: EquivalenceCase): method test_cluster_assignments (line 583) | def test_cluster_assignments(self, case: EquivalenceCase): method test_accuracy (line 596) | def test_accuracy(self, case: EquivalenceCase): method test_reconstruction (line 617) | def test_reconstruction(self, case: EquivalenceCase): FILE: test/conftest.py function pytest_addoption (line 26) | def pytest_addoption(parser): function update_golden (line 36) | def update_golden(request): FILE: test/generate_golden.py function main (line 28) | def main() -> None: FILE: test/same_cluster_as_input_data.py function input_data (line 31) | def input_data() -> pd.DataFrame: function test_same_cluster_as_input_data (line 58) | def test_same_cluster_as_input_data( FILE: test/test_accuracyIndicators.py function test_accuracyIndicators (line 8) | def test_accuracyIndicators(): FILE: test/test_adjacent_periods.py function test_adjacent_periods (line 10) | def test_adjacent_periods(): FILE: test/test_aggregate_hiearchical.py function test_aggregate_hiearchical (line 8) | def test_aggregate_hiearchical(): FILE: test/test_api_equivalence.py function sample_data (line 31) | def sample_data(): function small_data (line 37) | def small_data(sample_data): class TestAggregateEquivalence (line 42) | class TestAggregateEquivalence: method test_hierarchical_default (line 45) | def test_hierarchical_default(self, sample_data): method test_kmeans (line 88) | def test_kmeans(self, sample_data): method test_hierarchical_with_medoid (line 125) | def test_hierarchical_with_medoid(self, sample_data): method test_with_weights (line 151) | def test_with_weights(self, sample_data): method test_with_segmentation (line 180) | def test_with_segmentation(self, sample_data): method test_with_duration_curves (line 208) | def test_with_duration_curves(self, sample_data): method test_with_extremes_append (line 234) | def test_with_extremes_append(self, sample_data): method test_contiguous_clustering (line 262) | def test_contiguous_clustering(self, sample_data): method test_rescale_off (line 287) | def test_rescale_off(self, sample_data): method test_distribution_minmax_representation (line 314) | def test_distribution_minmax_representation(self, sample_data): class TestRepresentationObjects (line 343) | class TestRepresentationObjects: method test_distribution_global_equivalence (line 346) | def test_distribution_global_equivalence(self, sample_data): method test_distribution_cluster_equivalence (line 373) | def test_distribution_cluster_equivalence(self, sample_data): method test_distribution_minmax_global_equivalence (line 400) | def test_distribution_minmax_global_equivalence(self, sample_data): method test_minmaxmean_equivalence (line 427) | def test_minmaxmean_equivalence(self, sample_data): method test_segment_distribution_global_equivalence (line 457) | def test_segment_distribution_global_equivalence(self, sample_data): method test_segment_distribution_global_roundtrip (line 487) | def test_segment_distribution_global_roundtrip(self, sample_data, tmp_... method test_representation_object_json_roundtrip (line 509) | def test_representation_object_json_roundtrip(self, sample_data, tmp_p... class TestTuningEquivalence (line 537) | class TestTuningEquivalence: method test_find_clusters_for_reduction (line 540) | def test_find_clusters_for_reduction(self): method test_find_segments_for_reduction (line 561) | def test_find_segments_for_reduction(self): method test_find_optimal_combination (line 577) | def test_find_optimal_combination(self, sample_data): method test_find_pareto_front (line 617) | def test_find_pareto_front(self, small_data): method test_find_optimal_combination_save_all_results (line 655) | def test_find_optimal_combination_save_all_results(self, small_data): class TestSubhourlyResolution (line 674) | class TestSubhourlyResolution: method test_15min_resolution (line 677) | def test_15min_resolution(self): method test_tuning_with_15min_resolution (line 714) | def test_tuning_with_15min_resolution(self): class TestReconstructionEquivalence (line 740) | class TestReconstructionEquivalence: method test_reconstruct_matches_old_predict (line 743) | def test_reconstruct_matches_old_predict(self, sample_data): FILE: test/test_assert_raises.py function test_assert_raises (line 11) | def test_assert_raises(): FILE: test/test_averaging.py function test_averaging (line 10) | def test_averaging(): FILE: test/test_cluster_order.py function test_cluster_order (line 10) | def test_cluster_order(): FILE: test/test_clustering_e2e.py function _suppress_windows_kmeans_warnings (line 31) | def _suppress_windows_kmeans_warnings(case_id: str): function set_random_seed (line 48) | def set_random_seed(): class ClusteringTestCase (line 60) | class ClusteringTestCase(NamedTuple): function get_test_ids (line 176) | def get_test_ids(): function input_data (line 182) | def input_data(): function fixtures_dir (line 188) | def fixtures_dir(): function run_aggregation (line 193) | def run_aggregation(data: pd.DataFrame, test_case: ClusteringTestCase): class TestClusteringE2E (line 230) | class TestClusteringE2E: method test_cluster_representatives (line 234) | def test_cluster_representatives( method test_cluster_weights (line 265) | def test_cluster_weights( method test_accuracy_metrics (line 298) | def test_accuracy_metrics( function get_transfer_test_ids (line 349) | def get_transfer_test_ids(): class TestClusteringTransfer (line 354) | class TestClusteringTransfer: method test_apply_produces_identical_results (line 360) | def test_apply_produces_identical_results( method test_json_roundtrip_produces_identical_results (line 382) | def test_json_roundtrip_produces_identical_results( method test_reconstruction_shape (line 410) | def test_reconstruction_shape(self, test_case: ClusteringTestCase, inp... method test_apply_to_different_columns (line 422) | def test_apply_to_different_columns(self, input_data): method test_segmentation_preserved_in_transfer (line 441) | def test_segmentation_preserved_in_transfer(self, input_data, tmp_path): function generate_fixtures (line 472) | def generate_fixtures(output_dir: Path | None = None): FILE: test/test_disaggregate.py function sample_data (line 12) | def sample_data(): function result (line 17) | def result(sample_data): function result_segmented (line 22) | def result_segmented(sample_data): class TestAggregationResultDisaggregate (line 26) | class TestAggregationResultDisaggregate: method test_shape_matches_original (line 29) | def test_shape_matches_original(self, result): method test_datetime_index_restored (line 33) | def test_datetime_index_restored(self, result): method test_matches_reconstructed (line 37) | def test_matches_reconstructed(self, result): method test_columns_preserved (line 43) | def test_columns_preserved(self, result): method test_segmented_shape_matches_original (line 47) | def test_segmented_shape_matches_original(self, result_segmented): method test_segmented_datetime_index (line 53) | def test_segmented_datetime_index(self, result_segmented): method test_segmented_has_nan (line 59) | def test_segmented_has_nan(self, result_segmented): method test_segmented_ffill_removes_nan (line 66) | def test_segmented_ffill_removes_nan(self, result_segmented): method test_arbitrary_data (line 74) | def test_arbitrary_data(self, result): method test_subset_columns (line 83) | def test_subset_columns(self, result): method test_multiindex_columns (line 89) | def test_multiindex_columns(self, result): class TestClusteringResultDisaggregate (line 105) | class TestClusteringResultDisaggregate: method test_datetime_index_restored (line 108) | def test_datetime_index_restored(self, result): method test_integer_index_when_no_time_index (line 116) | def test_integer_index_when_no_time_index(self, result): method test_shape (line 124) | def test_shape(self, result): method test_segmented (line 130) | def test_segmented(self, result_segmented): method test_segmented_nan_count (line 138) | def test_segmented_nan_count(self, result_segmented): method test_timestep_input_on_segmented_clustering_raises (line 149) | def test_timestep_input_on_segmented_clustering_raises(self, result_se... method test_segmented_input_on_nonsegmented_clustering_raises (line 162) | def test_segmented_input_on_nonsegmented_clustering_raises(self, result): method test_io_roundtrip (line 176) | def test_io_roundtrip(self, result, tmp_path): method test_io_roundtrip_preserves_time_index (line 185) | def test_io_roundtrip_preserves_time_index(self, result, tmp_path): method test_io_roundtrip_no_time_index (line 198) | def test_io_roundtrip_no_time_index(self, tmp_path): method test_io_roundtrip_segmented (line 211) | def test_io_roundtrip_segmented(self, result_segmented, tmp_path): class TestTimeIndexSerialization (line 228) | class TestTimeIndexSerialization: method test_regular_index_compact (line 231) | def test_regular_index_compact(self): method test_regular_index_roundtrip (line 240) | def test_regular_index_roundtrip(self): method test_irregular_index_fallback (line 247) | def test_irregular_index_fallback(self): method test_old_list_format_still_loads (line 256) | def test_old_list_format_still_loads(self): class TestDisaggregateEdgeCases (line 264) | class TestDisaggregateEdgeCases: method test_padded_last_period (line 267) | def test_padded_last_period(self, sample_data): method test_single_cluster (line 276) | def test_single_cluster(self, sample_data): method test_extreme_periods_append (line 285) | def test_extreme_periods_append(self, sample_data): method test_extreme_periods_new_cluster (line 303) | def test_extreme_periods_new_cluster(self, sample_data): method test_kmeans (line 321) | def test_kmeans(self, sample_data): method test_segmented_nan_at_correct_positions (line 336) | def test_segmented_nan_at_correct_positions(self, result_segmented): method test_reconstructed_unchanged_by_refactor (line 363) | def test_reconstructed_unchanged_by_refactor(self, sample_data): class TestDisaggregateValidation (line 381) | class TestDisaggregateValidation: method test_flat_index_raises (line 384) | def test_flat_index_raises(self, result): method test_wrong_clusters_raises (line 388) | def test_wrong_clusters_raises(self, result): method test_missing_cluster_raises (line 394) | def test_missing_cluster_raises(self, result): method test_wrong_timesteps_raises (line 401) | def test_wrong_timesteps_raises(self, result): FILE: test/test_durationCurve.py function test_durationCurve (line 11) | def test_durationCurve(): FILE: test/test_durationRepresentation.py function test_durationRepresentation (line 19) | def test_durationRepresentation(): function test_distributionMinMaxRepresentation (line 94) | def test_distributionMinMaxRepresentation(): function test_distributionRepresentation_keeps_mean (line 126) | def test_distributionRepresentation_keeps_mean(): FILE: test/test_extremePeriods.py function test_extremePeriods (line 8) | def test_extremePeriods(): FILE: test/test_golden_regression.py function _expected_warnings (line 51) | def _expected_warnings(case: EquivalenceCase): function _expected_windows_kmeans_warnings (line 62) | def _expected_windows_kmeans_warnings(case: EquivalenceCase): function _golden_path (line 79) | def _golden_path(case: EquivalenceCase) -> str: function _save_golden (line 84) | def _save_golden(df: pd.DataFrame, case: EquivalenceCase) -> None: function _load_golden (line 90) | def _load_golden(case: EquivalenceCase) -> pd.DataFrame: class TestGoldenRegression (line 95) | class TestGoldenRegression: method test_update_golden (line 99) | def test_update_golden(self, case: EquivalenceCase, update_golden): method test_new_api_matches_golden (line 110) | def test_new_api_matches_golden(self, case: EquivalenceCase, update_go... method test_old_api_matches_golden (line 136) | def test_old_api_matches_golden(self, case: EquivalenceCase, update_go... FILE: test/test_hierarchical.py function test_hierarchical (line 10) | def test_hierarchical(): function test_hierarchical_for_weeks (line 58) | def test_hierarchical_for_weeks(): FILE: test/test_hypertuneAggregation.py function test_getPeriodPair (line 10) | def test_getPeriodPair(): function test_optimalPair (line 33) | def test_optimalPair(): function test_steepest_gradient_leads_to_optima (line 88) | def test_steepest_gradient_leads_to_optima(): function test_paretoOptimalAggregation (line 144) | def test_paretoOptimalAggregation(): FILE: test/test_k_maxoids.py function test_k_maxoids (line 16) | def test_k_maxoids(): FILE: test/test_k_medoids.py function test_k_medoids (line 10) | def test_k_medoids(): FILE: test/test_k_medoids_contiguity.py function test_node_cuts (line 34) | def test_node_cuts(): function test_k_medoids_simple (line 42) | def test_k_medoids_simple(): function test_k_medoids_simple_contiguity (line 61) | def test_k_medoids_simple_contiguity(): FILE: test/test_minmaxRepresentation.py function test_minmaxRepresentation (line 10) | def test_minmaxRepresentation(): FILE: test/test_new_api.py function sample_data (line 16) | def sample_data(): class TestAggregate (line 21) | class TestAggregate: method test_basic_aggregation (line 24) | def test_basic_aggregation(self, sample_data): method test_with_cluster_config (line 33) | def test_with_cluster_config(self, sample_data): method test_with_segmentation (line 47) | def test_with_segmentation(self, sample_data): method test_with_extremes (line 58) | def test_with_extremes(self, sample_data): method test_result_reconstructed (line 75) | def test_result_reconstructed(self, sample_data): method test_result_to_dict (line 82) | def test_result_to_dict(self, sample_data): method test_accuracy_metrics (line 91) | def test_accuracy_metrics(self, sample_data): class TestValidation (line 101) | class TestValidation: method test_invalid_n_clusters (line 104) | def test_invalid_n_clusters(self, sample_data): method test_invalid_data_type (line 112) | def test_invalid_data_type(self): method test_invalid_extreme_columns (line 117) | def test_invalid_extreme_columns(self, sample_data): method test_invalid_weight_columns (line 126) | def test_invalid_weight_columns(self, sample_data): method test_segments_exceeds_timesteps (line 135) | def test_segments_exceeds_timesteps(self, sample_data): class TestClusterConfig (line 146) | class TestClusterConfig: method test_default_representation (line 149) | def test_default_representation(self): method test_explicit_representation (line 155) | def test_explicit_representation(self): class TestImports (line 161) | class TestImports: method test_top_level_imports (line 164) | def test_top_level_imports(self): method test_version (line 175) | def test_version(self): class TestAssignments (line 182) | class TestAssignments: method test_assignments_basic (line 185) | def test_assignments_basic(self, sample_data): method test_assignments_with_segmentation (line 204) | def test_assignments_with_segmentation(self, sample_data): method test_assignments_values_valid (line 220) | def test_assignments_values_valid(self, sample_data): class TestSegmentTransfer (line 241) | class TestSegmentTransfer: method test_segment_assignments_and_durations_in_clustering (line 244) | def test_segment_assignments_and_durations_in_clustering(self, sample_... method test_segment_transfer (line 267) | def test_segment_transfer(self, sample_data): method test_segment_properties_none_without_segmentation (line 285) | def test_segment_properties_none_without_segmentation(self, sample_data): class TestClusteringResult (line 293) | class TestClusteringResult: method test_clustering_property_and_apply (line 296) | def test_clustering_property_and_apply(self, sample_data): method test_clustering_apply_with_segments (line 314) | def test_clustering_apply_with_segments(self, sample_data): method test_clustering_from_dict_and_json (line 332) | def test_clustering_from_dict_and_json(self, sample_data, tmp_path): method test_clustering_includes_period_duration (line 357) | def test_clustering_includes_period_duration(self, sample_data, tmp_pa... class TestDeterministicPreservation (line 375) | class TestDeterministicPreservation: method test_transfer_fields_preserved_in_json (line 378) | def test_transfer_fields_preserved_in_json(self, sample_data, tmp_path): method test_representation_method_deterministic (line 404) | def test_representation_method_deterministic(self, sample_data, tmp_pa... method test_apply_to_different_data (line 427) | def test_apply_to_different_data(self, sample_data): method test_segmentation_preserved_through_json (line 446) | def test_segmentation_preserved_through_json(self, sample_data, tmp_pa... method test_preserve_column_means_setting_preserved (line 474) | def test_preserve_column_means_setting_preserved(self, sample_data, tm... class TestSegmentConfigValidation (line 497) | class TestSegmentConfigValidation: method test_n_segments_must_be_positive (line 500) | def test_n_segments_must_be_positive(self): method test_valid_segment_config (line 508) | def test_valid_segment_config(self): class TestSegmentCenters (line 515) | class TestSegmentCenters: method test_segment_centers_with_medoid (line 518) | def test_segment_centers_with_medoid(self, sample_data): method test_segment_centers_none_with_mean (line 543) | def test_segment_centers_none_with_mean(self, sample_data): method test_segment_centers_preserved_in_json (line 554) | def test_segment_centers_preserved_in_json(self, sample_data, tmp_path): method test_segment_centers_deterministic_transfer (line 580) | def test_segment_centers_deterministic_transfer(self, sample_data): class TestDurationParsing (line 599) | class TestDurationParsing: method test_period_duration_string (line 602) | def test_period_duration_string(self, sample_data): method test_non_hour_period_duration (line 624) | def test_non_hour_period_duration(self): method test_temporal_resolution_string (line 642) | def test_temporal_resolution_string(self, sample_data): method test_invalid_duration_string (line 657) | def test_invalid_duration_string(self, sample_data): method test_invalid_duration_type (line 662) | def test_invalid_duration_type(self, sample_data): method test_negative_duration (line 667) | def test_negative_duration(self, sample_data): FILE: test/test_plot.py function sample_data (line 16) | def sample_data() -> pd.DataFrame: function result (line 21) | def result(sample_data) -> tsam.AggregationResult: function result_segmented (line 26) | def result_segmented(sample_data) -> tsam.AggregationResult: class TestValidateColumns (line 35) | class TestValidateColumns: method test_none_returns_all (line 36) | def test_none_returns_all(self): method test_valid_subset (line 39) | def test_valid_subset(self): method test_invalid_warns (line 42) | def test_invalid_warns(self): method test_all_invalid_raises (line 47) | def test_all_invalid_raises(self): class TestAccessor (line 55) | class TestAccessor: method test_plot_returns_accessor (line 56) | def test_plot_returns_accessor(self, result): class TestClusterRepresentatives (line 63) | class TestClusterRepresentatives: method test_returns_figure (line 64) | def test_returns_figure(self, result): method test_with_columns (line 68) | def test_with_columns(self, result): class TestClusterMembers (line 77) | class TestClusterMembers: method test_returns_figure (line 78) | def test_returns_figure(self, result): method test_single_column (line 83) | def test_single_column(self, result): method test_specific_clusters (line 88) | def test_specific_clusters(self, result): method test_slider_column (line 92) | def test_slider_column(self, result): method test_invalid_slider_raises (line 97) | def test_invalid_slider_raises(self, result): method test_invalid_clusters_warns (line 101) | def test_invalid_clusters_warns(self, result): method test_all_invalid_clusters_raises (line 106) | def test_all_invalid_clusters_raises(self, result): method test_representative_trace_matches_data (line 110) | def test_representative_trace_matches_data(self, result): method test_member_trace_contains_all_members (line 121) | def test_member_trace_contains_all_members(self, result): method test_with_segmentation (line 137) | def test_with_segmentation(self, result_segmented): method test_segmented_representative_expanded (line 141) | def test_segmented_representative_expanded(self, result_segmented): class TestClusterWeights (line 156) | class TestClusterWeights: method test_returns_figure (line 157) | def test_returns_figure(self, result): class TestAccuracy (line 165) | class TestAccuracy: method test_returns_figure (line 166) | def test_returns_figure(self, result): class TestSegmentDurations (line 174) | class TestSegmentDurations: method test_returns_figure (line 175) | def test_returns_figure(self, result_segmented): method test_raises_without_segmentation (line 179) | def test_raises_without_segmentation(self, result): class TestCompare (line 187) | class TestCompare: method test_overlay (line 188) | def test_overlay(self, result): method test_side_by_side (line 192) | def test_side_by_side(self, result): method test_duration_curve (line 196) | def test_duration_curve(self, result): method test_with_columns (line 200) | def test_with_columns(self, result): method test_invalid_mode_raises (line 205) | def test_invalid_mode_raises(self, result): class TestResiduals (line 213) | class TestResiduals: method test_time_series (line 214) | def test_time_series(self, result): method test_histogram (line 218) | def test_histogram(self, result): method test_by_period (line 222) | def test_by_period(self, result): method test_by_timestep (line 226) | def test_by_timestep(self, result): method test_with_columns (line 230) | def test_with_columns(self, result): method test_invalid_mode_raises (line 235) | def test_invalid_mode_raises(self, result): FILE: test/test_preprocess.py function test_preprocess (line 8) | def test_preprocess(): FILE: test/test_properties.py function test_properties (line 14) | def test_properties(): FILE: test/test_reconstruct_samemean_segmentation.py function test_data (line 22) | def test_data(): class TestReconstructSameMeanSegmentation (line 36) | class TestReconstructSameMeanSegmentation: method _check_reconstruction_bounds (line 39) | def _check_reconstruction_bounds( method test_segments_only (line 56) | def test_segments_only(self, test_data): method test_normalize_column_means_only (line 67) | def test_normalize_column_means_only(self, test_data): method test_normalize_column_means_with_segments (line 78) | def test_normalize_column_means_with_segments(self, test_data): method test_normalize_with_segments_mean_repr (line 92) | def test_normalize_with_segments_mean_repr(self, test_data): method test_normalize_with_different_segment_counts (line 104) | def test_normalize_with_different_segment_counts(self, test_data): FILE: test/test_samemean.py function test_samemean (line 18) | def test_samemean(): FILE: test/test_segmentation.py function test_segmentation (line 13) | def test_segmentation(): function test_representation_in_segmentation (line 61) | def test_representation_in_segmentation(): FILE: test/test_segmentation_weight_bug.py function _make_data (line 19) | def _make_data(): class TestSegmentationWeightLeak (line 49) | class TestSegmentationWeightLeak: method test_uniform_weights_equal_no_weights (line 52) | def test_uniform_weights_equal_no_weights(self): method test_reconstructed_means_not_scaled_by_weight (line 72) | def test_reconstructed_means_not_scaled_by_weight(self): method test_reconstructed_values_within_original_range (line 96) | def test_reconstructed_values_within_original_range(self): method test_segmentation_samemean_weights (line 118) | def test_segmentation_samemean_weights(self): FILE: test/test_subhourlyResolution.py function test_subhourlyResolution (line 14) | def test_subhourlyResolution(): FILE: test/test_subhourly_periods.py function test_subhourly_periods (line 12) | def test_subhourly_periods(): FILE: test/test_weightingFactors.py function test_weightingFactors (line 11) | def test_weightingFactors(): function test_uniform_weights_equal_no_weights (line 66) | def test_uniform_weights_equal_no_weights(): function test_reconstructed_within_original_range (line 90) | def test_reconstructed_within_original_range():