From 0f13c5c14e8735df1428e40bd853654d6229b12a Mon Sep 17 00:00:00 2001 From: aplowman Date: Wed, 3 Jan 2024 12:35:42 +0000 Subject: [PATCH] feat: add non-functional task schema for visualise_VE/pole_figure, pending VE parameter --- .../template_components/task_schemas.yaml | 69 +++++++++++++++++++ matflow/data/workflows/visualise_VE.yaml | 24 +++++++ 2 files changed, 93 insertions(+) create mode 100644 matflow/data/workflows/visualise_VE.yaml diff --git a/matflow/data/template_components/task_schemas.yaml b/matflow/data/template_components/task_schemas.yaml index 0c4e1b99..e04d8422 100644 --- a/matflow/data/template_components/task_schemas.yaml +++ b/matflow/data/template_components/task_schemas.yaml @@ -188,6 +188,75 @@ type: any environment: damask_parse_env +- objective: visualise_VE + method: pole_figure + implementation: mtex + inputs: + - parameter: volume_element + - parameter: crystal_symmetry + - parameter: pole_figure_directions + - parameter: use_contours + default_value: true + - parameter: IPF_reference_direction + default_value: z + - parameter: colourbar_limits + default_value: null + - parameter: use_one_colourbar + default_value: False + - parameter: compile + default_value: false + actions: + - script: <> + script_exe: compile_mtex + environments: + - scope: + type: any + environment: matlab_env + rules: + - path: inputs.compile + condition: + value.equal_to: true + + - script: plot_pole_figures + script_data_in: + volume_element.orientations: hdf5 + crystal_symmetry: json + pole_figure_directions: json + use_contours: json + IPF_reference_direction: json + colourbar_limits: json + use_one_colourbar: json + script_exe: run_compiled_mtex + environments: + - scope: + type: any + environment: matlab_env + save_files: [mtex_pole_figures, mtex_IPF_figure] + rules: + - path: inputs.compile + condition: + value.equal_to: true + + - script: <> + script_data_in: + volume_element.orientations: hdf5 + crystal_symmetry: json + pole_figure_directions: json + use_contours: json + IPF_reference_direction: json + colourbar_limits: json + use_one_colourbar: json + script_exe: run_mtex + environments: + - scope: + type: any + environment: matlab_env + save_files: [mtex_pole_figures, mtex_IPF_figure] + rules: + - path: inputs.compile + condition: + value.equal_to: false + - objective: sample_texture method: from_CTF_file implementation: mtex diff --git a/matflow/data/workflows/visualise_VE.yaml b/matflow/data/workflows/visualise_VE.yaml new file mode 100644 index 00000000..213848c9 --- /dev/null +++ b/matflow/data/workflows/visualise_VE.yaml @@ -0,0 +1,24 @@ +doc: + - A workflow to demonstrate tasks for visualising a volume element. + +tasks: + - schema: generate_volume_element_from_voronoi + inputs: + homog_label: SX + VE_grid_size: [64, 64, 64] + microstructure_seeds::from_random: + num_seeds: 2000 + box_size: [1, 1, 1] + phase_label: Al + + - schema: visualise_VE_VTK + + - schema: visualise_VE_pole_figure_mtex + inputs: + crystal_symmetry: cubic + pole_figure_directions: + - [0, 0, 1] + - [1, 0, 1] + - [1, 1, 1] + use_contours: false + compile: false