Skip to content

Commit c45d1bb

Browse files
author
dtyagi
committed
resolved error occured during specification of sim tools for filtering json-ld
1 parent eef9765 commit c45d1bb

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

benchmarks/linear-elastic-plate-with-hole/plot_metrics.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
from rdflib import Graph
44
import matplotlib.pyplot as plt
55
from collections import defaultdict
6-
from generate_config import workflow_config
76

87
def load_graphs(base_dir):
98
"""
@@ -25,12 +24,11 @@ def load_graphs(base_dir):
2524
return graph_list
2625

2726

28-
def query_and_build_table(graph_list):
27+
def query_and_build_table(graph_list, tools):
2928
"""
3029
Run SPARQL query on graphs and build a table.
3130
Returns headers and table_data.
3231
"""
33-
tools = workflow_config["tools"]
3432
filter_conditions = " || ".join(
3533
f'CONTAINS(LCASE(?tool_name), "{tool.lower()}")' for tool in tools
3634
)
@@ -147,7 +145,7 @@ def plot_element_size_vs_stress(headers, table_data, output_file="element_size_v
147145
parser = argparse.ArgumentParser(description="Process JSON-LD artifacts and display simulation results.")
148146
parser.add_argument("artifact_folder", type=str, help="Path to the folder containing unzipped artifacts")
149147
args = parser.parse_args()
150-
148+
tools = ["fenics", "kratos"] # Specify the simulation tools used for filtering knowledge graphs
151149
graphs = load_graphs(args.artifact_folder)
152-
headers, table_data = query_and_build_table(graphs)
150+
headers, table_data = query_and_build_table(graphs, tools)
153151
plot_element_size_vs_stress(headers, table_data, output_file="element_size_vs_stress.pdf")

0 commit comments

Comments
 (0)