<!-- source-page: 401 -->

# 3.2.8 Abaqus/Viewer EXECUTION

Product: Abaqus/Viewer

# Reference

• “Execution procedure for Abaqus: overview,” Section 3.1.1

# Overview

Abaqus/Viewer, a subset of Abaqus/CAE that contains only the postprocessing capabilities of the Visualization module, is executed by running the Abaqus execution procedure and specifying the viewer parameter.

Command summary 

<table><tr><td>abaqus viewer</td><td>[database=database-file] [replay=replay-file] [startup=startup-file] [script=script-file] [noGUI=[noGUI-file] ] [noenvstartup] [noSavedOptions] [noSavedGuiPrefs] [noStartupDialog] [custom=script-file] [guiTester=[GUI-script] ] [guiRecord] [guiNoRecord]</td></tr></table>

# Command line options

# database

This option specifies the name of the output database file to use if it is different from job-name. The procedure searches for database-file as entered on the command line with the .odb file extension.

# replay

This option specifies the name of the file from which Abaqus/Viewer commands are read. The commands in replay-file will execute immediately upon startup of Abaqus/Viewer. If no file extension is given, the default extension is .rpy. You cannot use the replay option to execute a script with control flow statements.

# startup

This option specifies the name of the file containing the Python configuration commands to be run at application startup. Commands in this file are run after any configuration commands that have been set in the environment file. Abaqus/Viewer does not echo the commands to the replay file when they are executed.

<!-- source-page: 402 -->

# script

This option specifies the name of the file containing Python configuration commands to be run at application startup. Commands in this file are run after any configuration commands that have been set in the environment file.

# noGUI

This option specifies that Abaqus/Viewer is to be run without the graphical user interface (GUI). If no file name is specified, an Abaqus/Viewer license is checked out and the Python interpreter is initialized to allow interactive entry of Python or Abaqus Scripting Interface commands.

If a file name is specified, Abaqus/Viewer runs the commands in the file and exits upon their completion. If no file extension is given, the default extension is .py. This option is useful for automating post-analysis processing tasks without the added expense of running a display. Since no interface is provided, the scripts cannot include any user interaction.

# noenvstartup

This option specifies that all configuration commands in the environment files should not be run at application startup. This option can be used in conjunction with the script command to suppress all configuration commands except those in the script file.

# noSavedOptions

This option specifies that Abaqus/Viewer should not apply the display options settings stored in abaqus\_2016.gpr (for example, the render style and the display of boundary conditions). For more information, see “Saving your display options settings,” Section 76.16 of the Abaqus/CAE User’s Guide.

# noSavedGuiPrefs

This option specifies that Abaqus/Viewer should not apply the GUI settings stored in abaqus\_2016.gpr (for example, the size and location of the Abaqus/CAE main window or its dialog boxes).

# noStartupDialog

This option specifies that the Start Session dialog box for Abaqus/Viewer should not be displayed.

# custom

This option specifies the name of the file containing Abaqus GUI Toolkit commands. This option executes an application that is a customized version of Abaqus/Viewer. For more information, see Chapter 1, “Introduction,” of the Abaqus GUI Toolkit User’s Guide.

# guiTester

This option starts a separate user interface containing the Python development environment along with Abaqus/Viewer. The Python development environment allows you to create, edit, step through, and debug Python scripts. For more information, see Part III, “The Abaqus Python development environment,” of the Abaqus Scripting User’s Guide.

<!-- source-page: 403 -->

You can specify a script as the argument for this option, which prompts Abaqus/Viewer to run a GUI script. Abaqus/Viewer closes when the end of the script is reached.

# guiRecord

This option enables you to record your actions in the Abaqus/Viewer user interface in a file named abaqus.guiLog. You can also set this option at startup by using the environment variable ABQ\_CAE\_GUIRECORD. The guiRecord option cannot be used with the guiTester option.

# guiNoRecord

This option enables you to disable user interface recording when the environment variable ABQ\_CAE\_GUIRECORD is set.

<!-- source-page: 404 -->

<!-- source-page: 405 -->

# 3.2.9 TOPOLOGY OPTIMIZATION EXECUTION

Product: Abaqus/CAE

# Reference

• “Execution procedure for Abaqus: overview,” Section 3.1.1

# Overview

Topology optimization using TOSCA for Abaqus is executed by running the Abaqus execution procedure and by providing the name of the parameter file, which, in turn, refers to an Abaqus input file. You can define your optimization model using Abaqus/CAE, and you can use the Optimization Process Manager to create the parameter file and the Abaqus/CAE input file.

Command summary 

<table><tr><td>abaqus optimization</td><td>task=parameter file</td></tr><tr><td></td><td>job=results folder</td></tr></table>

# Command line options

# task

This option is used to specify the file containing the parameters that are used to execute the optimization. The parameter file also contains information about the input file that is associated with the optimization. If this option is omitted from the command line, you will be prompted for this value.

# results folder

This option is used to specify the name of the folder in which the results of the optimization are stored. If this option is omitted from the command line, you will be prompted for this value.

# Examples

To run the optimization with the parameter file WeightReduction and the results folder WeightReductionResults, use the following command:

abaqus optimization task=WeightReduction job=WeightReductionResults

<!-- source-page: 406 -->

<!-- source-page: 407 -->

# 3.2.10 Python EXECUTION

Products: Abaqus/Standard Abaqus/Explicit

# Reference

• “Execution procedure for Abaqus: overview,” Section 3.1.1

# Overview

The Python language is used throughout Abaqus: in the Abaqus Scripting Interface, in the Abaqus environment file, and to perform parametric studies. The abaqus python facility is used to access the Python interpreter.

# Command summary

abaqus python

[script-file]

# Command line option

# script-file

The Python interpreter executes the instructions in the specified script-file. If this option is omitted from the command line, the Python interpreter is started in interactive mode.

<!-- source-page: 408 -->

<!-- source-page: 409 -->

# 3.2.11 PARAMETRIC STUDIES

Products: Abaqus/Standard Abaqus/Explicit

# References

• “Execution procedure for Abaqus: overview,” Section 3.1.1   
• “Abaqus/Standard, Abaqus/Explicit, and Abaqus/CFD execution,” Section 3.2.2

# Overview

The abaqus script facility indicates that a parametric study is to be done (see “Scripting parametric studies,” Section 20.1.1). Each analysis involved in the design can be executed using the execute command (see “Execute the analysis of parametric study designs.,” Section 20.2.4). You can add any necessary Abaqus execution options (refer to “Abaqus/Standard, Abaqus/Explicit, and Abaqus/CFD execution,” Section 3.2.2) to the execution command for each of the analyses by specifying them on the execOptions option of the execute command. If the script file contains references to other input files, these files must be located in the same directory as the script file. The files created by the execution of the script file are placed in the directory from which the Abaqus execution procedure is run.

Command summary 

<table><tr><td rowspan="3">abaqus script</td><td>[=script-file]</td></tr><tr><td>[startup=startup file-name]</td></tr><tr><td>[noenvstartup]</td></tr></table>

# Command line options

script-file

When a script file name is specified, the parametric study module is imported and the instructions in the parametric study script file are executed. If the script file name is omitted from the command line, the Python interpreter is initialized by importing the parametric study module.

# startup

This option specifies the name of the file containing Python configuration commands to be run at application startup. Commands in this file are run after any configuration commands that have been set in the environment file.

# noenvstartup

This option specifies that all configuration commands in the environment files should not be run at application startup. This option can be used in conjunction with the startup command to suppress all configuration commands except those in the startup file.

<!-- source-page: 410 -->

# Examples

Use the following command to execute the Python script in a file named “parstudy.psf”:

abaqus script=parstudy

The following command will initiate a Python scripting session:

abaqus script

In a Python scripting session the following command will execute the Python script in a file named “scriptfile”:

script("scriptfile")
