Batch mode

<< Click to Display Table of Contents >>

Navigation:  General >

Batch mode

Previous pageReturn to chapter overviewNext page

 

CFturbo can be executed in batch mode to modify designs without any screen display and user interaction. This is essential for using CFturbo with optimization software.

Syntax:

cfturbo.exe -batch <batch file> [-verbose] [-export <interface name>] [-log <log file>]

Example

CFturbo is installed in:
Batch file is:

c:\Program Files\CFturbo 2020.1\
c:\tmp\Example.cft-batch

"c:\Program Files\CFturbo 2020.1\cfturbo.exe" -batch c:\tmp\Example.cft-batch

Options:

-batch <batch file>

Enables CFturbo batch mode. <batch file> can either be a CFturbo batch file (*.cft-batch) or a CFturbo project file (*.cft).

-verbose

Display log output on the command line.

-export <interface name>

If CFturbo is started with a CFturbo project file in batch mode,
an export interface can be selected like in the batch file.

-log <log file>

Use specified logfile for output

All other batch commands have to be defined in a "Batch file".

Batch file

The batch mode of CFturbo is controlled by an XML file *.cft-batch.
For a specific CFturbo project this file can be created via PROJECT | Batch mode/ Optimization.

Due to a close relation between the CFturbo file format (*.cft) and the batch mode format (*.cft-batch), only batch mode files created with the same version as your CFturbo file should be used. After an update of CFturbo a new batch mode file can be created and the needed adjustments can be done.

The resulting batch mode file contains all selected parameters of the CFturbo project as XML nodes supplemented by a short description and optional range definitions.

File structure:

<?xml version="1.0" standalone="yes"?>

<CFturboFile Version="2020.1">

 <CFturboBatchProject InputFile="<InputFileName>">

         <Updates>

                 [...]

         </Updates>

         <BatchAction ...>

                 [...]

         </BatchAction>

         <BatchAction ...>

                 [...]

         </BatchAction>

 </CFturboBatchProject>

</CFturboFile>

A batch mode file can contain multiple elements of the CFturboBatchProject-type, each of which is handling a specific CFturbo project.This allows the combination of multiple batch mode files into one batch mode file.

All XML-subelements are optional and can occur multiple times except for the Updates-block which must occur once per CFturboBatchProject-element.

The InputFile-attribute of the CFturboBatchProject-element specifies the path of the CFturbo project file.

Updates

The Updates block contains all selected parameters that should be modified during batch run. These can be simple scalar values, points or arrays. Each parameters has his own description for more easy navigation in the file, e.g. for optimization setup.

Some general remarks to the parameter update:

Parameters are available for batch mode only if they can be modified in interactive design mode.
Examples:
- Impeller main dimensions, blade angles are available only if automatic calculation is disabled.
- Values for splitter blades are available when splitters are not geometrically linked to main blades.

Parameters can be modified within the same constraints that exist in interactive design mode. Modifications that violate the constraints will be corrected automatically.

All parameters of the Updates block with their new values after the batch run are saved in a resulting parameter file <name of batch file>.cft-res. The file structure is identical to the batch file *.cft-batch and allows a comparison between the desired and the realized parameter value which takes all restrictions into account.

Batch actions

Two different actions are available for further processing of the CFturbo projects loaded in batch mode. The BatchAction-element can occur multiple times, e.g. for exporting multiple parts of the geometry in different modelstates or saving an updated geometry.

<BatchAction Name="Export" ExportInterface="STEP" WorkingDir="c:\Examples\Myexports" BaseFileName="Pump1_all" ModelState="Solids only" AllComponents=""/>

The Export-action is used to export the project data utilizing the export interfaces CFturbo supports.

By default the active component (Predefined 3D model export/ Point based export) or geometry elements as configured in the active Model state (3D model export) are exported.
Depending on the export interface a selection of the components to export can either be done using the ModelState-attribute (3D model export) or the ExportComponents-subelement (Predefined 3D model export/ Point based export). For details about the supported selection options for the specific interface see Project | Export.

Attribute

Value

optional

Description

Name

Export

no

Name of action

ExportInterface

e.g. "General"

no

Export interface to use. The following values are valid:

AnsysMesher

AutoCAD

BladeGen

BREP

Catia

CFturboExchange

CreoParametric

DXF

General

IcemSTEP

IGES

Inventor

MeridianContour

NumecaAG

NumecaIGG

NX

OpenFOAM

Parasolid

PerformanceData

Pointwise

Report

SpaceClaim

Simerics

SolidWorks

StarCCM

STEP

STL

TetraVolMesh

TurboGrid

TurbomachineryCFD

VistaTF

WorkingDir

<existing path>

yes

Folder for exported files

BaseFileName

<filename>

yes

File name without extension

ModelState

<existing model state>

yes

Model state to select for export

AllComponents

empty

yes

Select all components for export, Note: Only components which are supported by the export interface will be exported!

The ExportComponents-subelement is a list of components that should be exported.

<BatchAction Name="Save" OutputFile="C:\Examples\Impeller\Pump1_new.cft"/>

Is used for saving the CFturbo project after applying batch updates. It can also be used for the automatic conversion of CFturbo files created with older program versions.
The OutputFile attribute specifies the path of the file save destination.