About File Parameters

File parameters are special parameters that Isight can read from and write to while executing a model. Similar to parameters, file parameters can either be input or output and can be mapped between components. File parameters are either scalars, arrays, or file sets. The advantage that file parameters offer is that instead of copying the data from the file, Isight copies information about where the data resides. Therefore, you do not have to copy the data around while Isight executes models.

This page discusses:

Isight can copy the contents of an input file parameter into the working directory or any other local directory before a component runs. Similarly, Isight can copy output files from the working directory or another location into an output file parameter after the component runs. This allows components designed for local execution to be distributed across the network without changes. You can specify the name of the local file if the program requires input or output files with a specific name. Otherwise, Isight selects the file name and makes it available to the component when the component executes.

The locations of file parameters are saved with the other run results. You can view and save the contents of a file parameter from the Isight Runtime Gateway. The contents of a file parameter can be viewed using button available at the end of file name in both Parameter and History tab of the Isight Runtime Gateway. The contents of the file parameter(created using text file format) can be saved to your local directory by click on button. For more information, see About the File Type

Similar to parameters, file parameters are defined by their attributes. You can give a file parameter a name, which is separate from the name of the file to which the file parameter points (see About File Parameter Names). In addition, you can define a shorter display name that is easier to read in visuals. Display names for file parameters are the same as for parameters. For more information, see About Display Names.

You can determine whether or not you want to save the file parameter to the results database. For more information, see About Saving File Parameters to the Database.

When you add a new input or output file parameter, you need to specify an associated source and destination. The terms have different meanings for input and output file parameters. For an input file parameter, the source is the location where the file will reside prior to the component executing and the destination is the location where the runtime environment will copy the file so that the file will be available when the component executes. For an output file parameter, the source is the location where the file will exist after the component executes and the destination is the location where the runtime environment will copy the file before Isight removes the component’s runtime directory. For more information, see About Configuring the Source or Destination for File Parameters. For information about configuring file sets, see Adding File Sets.

You can map a file parameter from one component to a file parameter in another component during execution. For file sets, you can map a file set to another file set, a file set to a resizable array of files, and a resizable array of files to a file set. A mapped input file parameter behaves differently from an unmapped one; the source configuration is ignored for a mapped input file, and the contents of the file parameter that is mapped to this input parameter are used instead. For more information, see Mapping Parameters and File Parameters.

Isight can adjust how it references a file parameter to account for the differences caused by the fact that shared or network file systems are often named differently on different computers. For more information, see About File Parameters on Shared or Network File Systems.

You can also select the format of the file and the encoding (how bytes are converted into characters). For more information, see About the File Type and About Encoding.

The following figure shows an example of the Files tab.



About File Parameter Names

The file parameter name is separate from the name of the file to which the file parameter points. It is the name to look for on the Mappings subtab when mapping file parameters and is also the column heading on the Runtime Gateway Parameters and History tabs.

The default parameter name for a file parameter is the name of the file with any directory names removed and the period before the file type changed to an underscore (a period is not a valid character in parameter names).

About Saving File Parameters to the Database

File parameters are often used for temporary work, so it is often desirable to not store the information for these files in the database. File parameters that are not saved will not be displayed in the Parameters or History tabs on the Runtime Gateway during or after execution. Output file parameters that are not saved can still be mapped to other components. The contents of the file are kept until they are no longer needed for mapping. As part of the execution process, Isight does not save file parameters to the database. You can specify whether or not you want to save file parameters to the database when you add a new file parameter, or you can use the Files tab after adding the file parameter to edit your choice. For more information, see Editing Parameters.

You can also set a preference option for saving file parameters to the database. For more information, see Setting Gateway Preferences.

About Configuring the Source or Destination for File Parameters

When you add an input and output file parameter, you must specify a source and destination.

The source for an input file parameter is the location where the file will exist prior to the component executing. The destination for an input file parameter is the location where the runtime environment will copy the file so that the file will be available when the component executes.

The source for an output file parameter is the location where the file will exist after the component executes. The destination for an output file parameter is the location where the runtime environment will copy the file before Isight removes the component’s runtime directory.

Isight supports the following source and destination locations:

Source/Destination

Input File Parameters

Output File Parameters

Source

Destination

Source

Destination

File

Y

N

Y

Y

File Set

Y

N

Y

N

File Parameter in Another Component

Y

N

N

N

File Stored In Model

Y

N

N

N

FTP

Y

N

N

Y

URL

Y

N

N

Y

Fixed File Name

N

Y

N

N

Automatic

N

Y

N

N

Isight File Manager

N

N

N

Y

None

N

N

N

Y

The source and destination options are described as follows:

File

Select this option to use a specific file. For input file parameters, the value is displayed in the In From column on the Input Files subtab. If the input file parameter is mapped, this information is overridden by the parameter that is mapped into it. For output file parameters, the source value is displayed in the Runtime column on the Output Files subtab whereas the destination value is displayed in the Out To column on the Output Files subtab. An output file parameter that is saved in a fixed location is not safe for parallel execution because multiple instances of the component overwrite each other’s data. For more information, see Configuring a File as the Source or Destination.

Note: When the source for an input file parameter is set to File, it is possible for the parameter and the file to become disassociated (e.g., if the file is moved, renamed, or deleted). Isight periodically checks the file parameters in the currently loaded model to see whether this situation has occurred or has been corrected. For example, you may send the model to another user without sending the file that serves as the source file for an input file parameter. If this occurs, Isight issues a model validation warning.

File Set
Select this option to use a specific set of files in a directory. For input file set parameters, the value is displayed in the In From column on the Input Files subtab. If the input file set parameter is mapped, this information is overridden by the parameter that is mapped into it. For output file set parameters, the source value is displayed in the Runtime Column on the Output Files subtab. For more information, see Adding File Sets.
File Parameter in Another Component

Select this option to select an existing file parameter in a different component to map to the input file parameter. The value is displayed in the In From column on the Input Files subtab. If the input file parameter is mapped, this information is overridden by the parameter that is mapped into it.

File Stored in Model

Select this option to use a file that is stored within the model. The value is displayed in the In From column on the Input Files subtab. If the input file parameter is mapped, this information is overridden by the parameter that is mapped into it. For more information, see Configuring a Data File Stored within the Isight Model as the Input Source.

FTP

Select this option to enter an FTP site and a file name. For input file parameters, the value is displayed in the In From column on the Input Files subtab. If the input file parameter is mapped, this information is overridden by the parameter that is mapped into it. For output file parameters, the source value is displayed in the Runtime column on the Output Files subtab whereas the destination value is displayed in the Out To column on the Output Files subtab. An output file parameter that is saved in a fixed location is not safe for parallel execution because multiple instances of the component overwrite each other’s data. For more information, see Configuring an FTP Site as the Input Source or Output Destination.

URL

Select this option to specify a URL. For input file parameters, the value is displayed in the In From column on the Input Files subtab. If the input file parameter is mapped, this information is overridden by the parameter that is mapped into it. For output file parameters, the source value is displayed in the Runtime column on the Output Files subtab whereas the destination value is displayed in the Out To column on the Output Files subtab. An output file parameter that is saved in a fixed location is not safe for parallel execution because multiple instances of the component overwrite each other’s data. For more information, see Configuring a URL as the Input Source or Output Destination.

Note: An output URL file parameter that uses the http: or https: protocol relies on the web server to accept a PUT request from the client. Most web servers do not allow PUT requests for security reasons.

Fixed File Name

Select this option to copy the source file to a specified directory. The value is displayed in the Runtime column on the Input Files subtab.

Automatic

Select this option if this parameter is mapped from a file. File source parameters are referenced by the component in their current location. The value is displayed in the Runtime column on the Input Files subtab.

Isight File Manager

Select this option to have the Isight file manager store the content of the file in the Isight runtime database. The Isight file manager is part of the results database that stores the contents of output file parameters that are marked with a destination of Isight File Manager. The value is displayed in the Out To column on the Output Files subtab.

None

Select this option to not copy the file parameter. Instead, the source file’s absolute path is stored. The value (None) is displayed in the Out To column on the Output Files subtab.

About File Parameters on Shared or Network File Systems

Isight can adjust how it references a file parameter to account for the differences caused by the fact that shared or network file systems are often named differently on different computers.

With a shared or network file system, for example, a user’s home directory might be /home/user on the user’s Linux workstation and /net/host/user on other Linux workstations. At the same time, it might be mounted as H:\ on a Windows workstation and be available as \\host\user on other Windows computers.

Instead of using an absolute path, which can be incorrect on some computers, Isight references the file parameter as a path relative to a symbolic root directory. On each computer, the symbolic root directory is set to the location where that computer mounts the shared file system. Each time the file parameter is referenced (by the Design Gateway, Runtime Gateway, or a SIMULIA Execution Engine station), the local symbolic root value is used to build the absolute path to the file parameter that is appropriate for that computer.

Symbolic roots for the Design Gateway and Runtime Gateway are defined using the Isight preferences. For more information, see Setting Preferences. Symbolic root directories for SIMULIA Execution Engine stations are set in the Symbolic root directories section of the station.properties file. For more information, refer to the SIMULIA Execution Engine Installation and Configuration Guide for your installation.

About the File Type

When you are working with file parameters, you can choose the format (text or binary) of the file. Text files are displayed faster than binary files in the Runtime Gateway and can be converted from a nonstandard character encoding. Binary files are always copied unchanged and are displayed in an external Web browser. Whether a binary file can be viewed or not depends on what file formats are recognized by your Web browser.

About Encoding

In a Locale (a system setting that includes the language, number formats, and character set in use) that uses multibyte characters (Japanese, Chinese, Korean), there is a default encoding used to convert bytes into characters. Most text files are written using this encoding, but sometimes it is necessary to specify the encoding. For additional information on encoding, see File Type and Encoding in the Isight Development Guide.

Encoding is used for file parameters that use a file or an FTP file as the source or destination. It is used to control how the bytes are read from the disk or the network are converted to characters.

Note: You can control the default encoding by setting a preference option. For more information, see Setting Preferences.