From 7f596c7bdffececd01dbf7ee704d96a28c32ac96 Mon Sep 17 00:00:00 2001 From: Ardt Klapwijk <59741981+ArdtK@users.noreply.github.com> Date: Thu, 9 Jan 2025 19:32:23 +0100 Subject: [PATCH] =?UTF-8?q?chore:=20be=20explicit=20on=20inputs=20to=20sin?= =?UTF-8?q?gle=20link=20losses=20and=20redundancy=20ana=E2=80=A6=20(#680)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ra2ce/analysis/analysis_factory.py | 1 - ra2ce/analysis/losses/single_link_losses.py | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ra2ce/analysis/analysis_factory.py b/ra2ce/analysis/analysis_factory.py index eaac03bb8..a01714ea0 100644 --- a/ra2ce/analysis/analysis_factory.py +++ b/ra2ce/analysis/analysis_factory.py @@ -175,7 +175,6 @@ def get_losses_analysis( _analysis_input = AnalysisInputWrapper.from_input( analysis=analysis, analysis_config=analysis_config, - graph_file=analysis_config.graph_files.base_graph_hazard, graph_file_hazard=analysis_config.graph_files.base_graph_hazard, ) return SingleLinkLosses(_analysis_input, analysis_config) diff --git a/ra2ce/analysis/losses/single_link_losses.py b/ra2ce/analysis/losses/single_link_losses.py index 3f6f4040c..55dbe410d 100644 --- a/ra2ce/analysis/losses/single_link_losses.py +++ b/ra2ce/analysis/losses/single_link_losses.py @@ -12,4 +12,6 @@ class SingleLinkLosses(LossesBase): """ def _get_criticality_analysis(self) -> SingleLinkRedundancy: + # Provide the graph file with hazard overlay if it's result is consumed by a losses analysis. + self.analysis_input.graph_file = self.analysis_input.graph_file_hazard return SingleLinkRedundancy(self.analysis_input)