There are four actions that the external executable program must be able to perform:
Initializing the ApproximationThe following is the sequence of events that occur when Isight initializes the approximation. Isight executes all sampling points using the built-in sampling mechanism and creates the following files in the execution directory (see File Formats Used by External Executable Approximation Plug-ins):
Isight calls the external executable program using the following command syntax: my.exe initialize -techniqueOptionsFile techniqueOptionsFileName -inputMatrixFile inputMatrixFileName -outputMatrixFile outputMatrixFileName -internalDataFile internalDataFileName where:
The external executable program does the following:
Isight reads the internal data file created by the external executable program and stores its contents in memory. The approximation is considered initialized at this time. Isight provides the internal data again as a local file when the approximation is evaluated or exported. Evaluating the ApproximationThe following is the sequence of events that occur when Isight evaluates the approximation. Isight creates the following files in the execution directory (see File Formats Used by External Executable Approximation Plug-ins):
Isight calls the external executable program using the following command syntax: my.exe evaluate -inputMatrixFile inputMatrixFileName -outputMatrixFile outputMatrixFileName -internalDataFile internalDataFileName -inputValuesFile inputValuesFileName -outputValuesFile outputValuesFileName where:
The external executable approximation program does the following:
Isight reads the output values from the specified output values file. Exporting the Approximation Coefficient DataThe following is the sequence of events that occur when Isight exports the approximation coefficient data to a readable format file. Isight creates an internal data file in the execution directory (see File Formats Used by External Executable Approximation Plug-ins). Isight calls the external executable program using the following command syntax: my.exe export -exportToFile exportFileName -internalDataFile internalDataFileName where:
The external executable program reads the internal data file and writes its coefficient data to a file (exportFileName) in a readable format. When writing the approximation’s coefficient data, it is recommended that you start with an easily recognizable title string (e.g., "MY APPROXIMATION COEFFICIENTS"), so that the external executable program can easily find this string when performing the reverse operation of loading approximation coefficient data from a file. Isight reads the exported coefficient data from the specified file and appends it to the standard text data to be shown on the Approximation Initialization dialog box in the Design Gateway or on the Visual Design tab in the Runtime Gateway. Loading the Approximation Coefficient DataThe following is the sequence of events that occur when Isight loads the approximation coefficient data from a file to a readable format: Isight copies the coefficient data file into a local directory (see File Formats Used by External Executable Approximation Plug-ins). Isight calls the external executable program using the following command syntax: my.exe load -loadFromFile coefficientDataFileName -internalDataFile internalDataFileName where:
The external executable program reads the coefficient data file, and creates a file with its internal data (internalDataFileName) in the same format that was used during initialization. The coefficient data file provided by Isight contains various standard information at the beginning of the file, including parameter names, input matrix, and output matrix, as can be seen when viewing any initialized approximation in the Approximation Initialization dialog box in the Design Gateway. The external executable program must find the coefficient data section at the end of the file. This section will be exactly the same as written by your external executable program during the export action (see Exporting the Approximation Coefficient Data). Isight reads the internal data file created by the external executable program and stores its contents in memory. The approximation is considered initialized at this time. Isight provides the internal data again as a local file when the approximation is evaluated or exported. |