From 7a2fec4d2002353de2a562b9477099323b040f0c Mon Sep 17 00:00:00 2001 From: Michael Atkinson Date: Tue, 12 Jan 2021 16:07:28 +0000 Subject: [PATCH] Add implementation of task `modify_volume_element` by method `add_buffer_zones` --- matflow_damask/main.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/matflow_damask/main.py b/matflow_damask/main.py index 9b55927..7b991de 100644 --- a/matflow_damask/main.py +++ b/matflow_damask/main.py @@ -20,6 +20,7 @@ get_header_lines, parse_damask_spectral_version_info, volume_element_from_2D_microstructure, + add_volume_element_buffer_zones, ) from damask_parse import __version__ as damask_parse_version from matflow.scripting import get_wrapper_script @@ -292,6 +293,17 @@ def volume_element_from_microstructure_image(microstructure_image, depth, image_ return out +@func_mapper(task='modify_volume_element', method='add_buffer_zones') +def modify_volume_element_add_buffer_zones(volume_element, buffer_sizes, + phase_ids, phase_labels, homog_label, order): + out = { + 'volume_element': add_volume_element_buffer_zones( + volume_element, buffer_sizes, phase_ids, phase_labels, homog_label, order + ) + } + return out + + @func_mapper(task='visualise_volume_element', method='VTK') def visualise_volume_element(volume_element): from damask import Geom