From 8f5bc1a8f5063b42cc0831baabc5f2bc85714d4e Mon Sep 17 00:00:00 2001 From: afwillia Date: Mon, 26 Aug 2024 14:29:53 -0700 Subject: [PATCH] set self.graph_data_model and update it if data_model_grapher is not provided --- schematic/visualization/attributes_explorer.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/schematic/visualization/attributes_explorer.py b/schematic/visualization/attributes_explorer.py index e768d1ab6..5fbc2c210 100644 --- a/schematic/visualization/attributes_explorer.py +++ b/schematic/visualization/attributes_explorer.py @@ -34,7 +34,7 @@ def __init__( self.jsonld = load_json(self.path_to_jsonld) if data_model_graph_pickle and not graph_data_model: - graph_data_model = read_pickle(data_model_graph_pickle) + self.graph_data_model = read_pickle(data_model_graph_pickle) # Parse Model if not parsed_data_model: @@ -46,9 +46,8 @@ def __init__( # Instantiate DataModelGraph if not data_model_grapher: data_model_grapher = DataModelGraph(parsed_data_model, data_model_labels) - - # Generate graph - self.graph_data_model = data_model_grapher.graph + # Generate graph + self.graph_data_model = data_model_grapher.graph # Instantiate Data Model Graph Explorer if not data_model_graph_explorer: