From 9a75c13398f19dd24c2ab5046949672868a77767 Mon Sep 17 00:00:00 2001 From: Thomas Guillod Date: Fri, 8 Sep 2023 20:27:42 +0200 Subject: [PATCH] better bash scripts for the examples --- examples/run_plotter.py | 2 +- examples/run_plotter.sh | 5 ++++- examples/run_viewer.py | 2 +- examples/run_viewer.sh | 5 ++++- 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/examples/run_plotter.py b/examples/run_plotter.py index f51bcb44..b0298908 100644 --- a/examples/run_plotter.py +++ b/examples/run_plotter.py @@ -24,7 +24,7 @@ file_point = os.path.join(PATH_ROOT, FOLDER_NAME, EXAMPLE_NAME, "point.yaml") file_plotter = os.path.join(PATH_ROOT, FOLDER_CONFIG, "plotter.yaml") - # plot type + # plot tag (from plotter.yaml) tag_plot = [ "material", "V_c_abs", diff --git a/examples/run_plotter.sh b/examples/run_plotter.sh index 8e71aa84..56eee6aa 100755 --- a/examples/run_plotter.sh +++ b/examples/run_plotter.sh @@ -15,10 +15,13 @@ FILE_SOLUTION="$PATH_ROOT/$FOLDER_NAME/$EXAMPLE_NAME/solution.pck" FILE_POINT="$PATH_ROOT/$FOLDER_NAME/$EXAMPLE_NAME/point.yaml" FILE_PLOTTER="$PATH_ROOT/$FOLDER_CONFIG/plotter.yaml" +# plot tag (from plotter.yaml) +TAG_PLOT="material V_c_abs J_c_norm_re B_m_norm_abs H_norm_abs convergence residuum" + # run pypeec plotter \ --solution $FILE_SOLUTION \ --point $FILE_POINT \ --plotter $FILE_PLOTTER \ - --tag_plot material V_c_abs J_c_norm_re B_m_norm_abs H_norm_abs convergence residuum \ + --tag_plot $TAG_PLOT \ --plot_mode qt diff --git a/examples/run_viewer.py b/examples/run_viewer.py index 378d3a02..e8bcbbd4 100644 --- a/examples/run_viewer.py +++ b/examples/run_viewer.py @@ -24,7 +24,7 @@ file_point = os.path.join(PATH_ROOT, FOLDER_NAME, EXAMPLE_NAME, "point.yaml") file_viewer = os.path.join(PATH_ROOT, FOLDER_CONFIG, "viewer.yaml") - # plot type + # plot tag (from viewer.yaml) tag_plot = ["domain", "connection"] # run viewer diff --git a/examples/run_viewer.sh b/examples/run_viewer.sh index 29975ad7..c15c0132 100755 --- a/examples/run_viewer.sh +++ b/examples/run_viewer.sh @@ -15,10 +15,13 @@ FILE_VOXEL="$PATH_ROOT/$FOLDER_NAME/$EXAMPLE_NAME/voxel.pck" FILE_POINT="$PATH_ROOT/$FOLDER_NAME/$EXAMPLE_NAME/point.yaml" FILE_VIEWER="$PATH_ROOT/$FOLDER_CONFIG/viewer.yaml" +# plot tag (from viewer.yaml) +TAG_PLOT="domain connection" + # run pypeec viewer \ --voxel $FILE_VOXEL \ --point $FILE_POINT \ --viewer $FILE_VIEWER \ - --tag_plot domain connection \ + --tag_plot $TAG_PLOT \ --plot_mode qt