.. _auto_lsdyna_prepost_command: *LS-PREPOST COMMAND RUNNER* =========================== Executes predefined or custom LS-PrePost commands on LS-DYNA keyword or d3plot files. Supports templated tasks (change material, change section thickness, delete elements, transform part, reference check, add keyword card, generate image, scale/reflect parts, merge nodes, import keywords, list/edit materials, edit initial velocity) with validated parameters, plus a raw command escape hatch for arbitrary LS-PrePost operations. Returns a detailed status log, modified files, and LS-PrePost output. When to use ----------- Tagged: ``d3plot``, ``deck-editing``, ``geometry``, ``keyword``, ``ls-prepost``, ``lsdyna``, ``material``, ``mesh``. Inputs ------ .. list-table:: :header-rows: 1 :widths: 20 20 20 20 20 20 * - Label - ID - Type - Default - Required - Description * - Simulation - simulation_id - remote_lookup - — - - d3VIEW simulation record whose primary keyword (.k) or d3plot file will be opened; mutually exclusive with the direct `file` input — leave blank if providing a file path directly. * - File - file - file - — - - Direct LS-DYNA keyword (.k/.key/.dyn) or d3plot file to operate on; mutually exclusive with `simulation_id` — leave blank when resolving via a simulation record. * - Task Type - task_type - select - none - - Predefined LS-PrePost task to execute (e.g. change_material, generate_image, merge_duplicate_nodes); select 'none' to skip templated task logic and supply only raw_commands. * - Task Parameters (JSON) - task_params - textarea - — - - JSON object supplying parameters for the chosen task_type (e.g. {"part_id":1,"new_mat_id":5} for change_material); required keys vary by task — see worker documentation; leave empty when task_type is 'none'. * - Part ID - part_id - text - — - - The part ID to operate on * - New Material ID - new_mat_id - text - — - - The material ID to assign to the part * - Section ID - section_id - text - — - - The section ID to modify * - Thickness - thickness - text - — - - New thickness value for the section * - Element IDs - element_ids - text - — - - Comma-separated list of element IDs to delete * - Element Type - element_type - select - shell - - Type of elements to delete * - Translate X (dx) - dx - text - 0 - - Translation distance in X direction * - Translate Y (dy) - dy - text - 0 - - Translation distance in Y direction * - Translate Z (dz) - dz - text - 0 - - Translation distance in Z direction * - Rotate X (rx) - rx - text - 0 - - Rotation angle about X axis (degrees) * - Rotate Y (ry) - ry - text - 0 - - Rotation angle about Y axis (degrees) * - Rotate Z (rz) - rz - text - 0 - - Rotation angle about Z axis (degrees) * - Keyword Card Content - card_content - textarea - — - - Raw keyword card block starting with * (e.g. *CONTACT_AUTOMATIC_SURFACE_TO_SURFACE) * - View Angle - view_angle - select - — - - Camera view angle for the image * - Time State - time_state - text - 0 - - Time state index for d3plot files (0 = first, -1 = last) * - Fringe Component - fringe_component - text - — - - Fringe component to display (e.g. Effective Stress (v-m)) * - Zoom - zoom - text - 1.0 - - Zoom factor (e.g. 1.0 = default) * - Image Size - image_size - text - 1920x1080 - - Image dimensions in pixels (e.g. 1920x1080) * - Scale Factor - factor - text - — - - Uniform scale factor for the part * - Center X - center_x - text - — - - X coordinate of the scaling center (auto-computed if omitted) * - Center Y - center_y - text - — - - Y coordinate of the scaling center (auto-computed if omitted) * - Center Z - center_z - text - — - - Z coordinate of the scaling center (auto-computed if omitted) * - Mirror Plane - plane - select - — - - Plane to reflect/mirror the part about * - Create Copy - copy_flag - select - — - - Whether to create a copy or move the original * - Merge Tolerance - tolerance - text - 0.01 - - Distance tolerance for merging duplicate nodes * - Part IDs - part_ids - text - — - - Comma-separated list of part IDs to delete * - Import File - import_file - file - — - - Keyword file to import/append into the current model * - Material ID - mat_id - text - — - - The material ID to edit * - Field Changes (JSON) - field_changes - textarea - — - - JSON object mapping parameter names to new values, e.g. {"SIGY": 450, "E": 210} * - Material Type - mat_type - text - — - - Material type keyword (e.g. MAT_PIECEWISE_LINEAR_PLASTICITY). Auto-detected if omitted. * - Scale Factor X - factor_x - text - 1.0 - - Scale factor in the X direction * - Scale Factor Y - factor_y - text - 1.0 - - Scale factor in the Y direction * - Scale Factor Z - factor_z - text - 1.0 - - Scale factor in the Z direction * - Velocity X (vx) - vx - text - — - - Translational velocity in X direction * - Velocity Y (vy) - vy - text - — - - Translational velocity in Y direction * - Velocity Z (vz) - vz - text - — - - Translational velocity in Z direction * - Rotational Velocity X (vxr) - vxr - text - — - - Rotational velocity about X axis * - Rotational Velocity Y (vyr) - vyr - text - — - - Rotational velocity about Y axis * - Rotational Velocity Z (vzr) - vzr - text - — - - Rotational velocity about Z axis * - Raw LS-PrePost Commands - raw_commands - textarea - — - - Raw LS-PrePost commands (one per line). These are appended after any task commands. Use this for operations not covered by predefined tasks, or to add extra commands after a task. Outputs ------- .. list-table:: :header-rows: 1 :widths: 20 20 20 20 * - Label - ID - Type - Description * - Status Log - status - text - Structured plain-text status log with tagged entries ([VALIDATE], [RESOLVE], [TASK], [EXECUTE], [OUTPUT], [DONE], [ERROR]) describing validation results, execution progress, and outcome. * - Output File - output_file - text - Filesystem path to the primary output artifact — the modified keyword file after deck-editing tasks, or the rendered image file after a generate_image task. * - Output Files - files - dataset - Dataset listing all files produced in the worker's working directory during the run, including intermediate and auxiliary outputs. * - STDOUT - stdout - textarea - Raw standard-output text captured from the LS-PrePost process; useful for diagnosing warnings or unexpected LS-PrePost messages. * - Command File - command_file - textarea - Full LS-PrePost command script (.cfile) that was assembled and executed; inspect this for debugging or to replay operations outside the worker. * - Materials - materials - dataset - Tabular dataset of material cards extracted from the keyword file (columns: mat_id, type, title, density, youngs_modulus, poissons_ratio, raw_card); populated only when task_type is 'list_materials', empty otherwise. Disciplines ----------- - cae.postprocessing.visualization - cae.preprocessing.deck_authoring - cae.preprocessing.setup - engineering.material.library .. raw:: html

Auto-generated from platform schema. Worker id: lsdyna_prepost_command. Schema hash: aa3bf0f5eebb. Hand-curated docs in workerexamples/ override this page when present.