conversion_of_confidential_models_for_submission_to_gams_support

This shows you the differences between two versions of the page.

Both sides previous revision Previous revision Next revision | Previous revision | ||

conversion_of_confidential_models_for_submission_to_gams_support [2011/04/20 16:48] support |
conversion_of_confidential_models_for_submission_to_gams_support [2017/09/02 19:02] (current) support |
||
---|---|---|---|

Line 8: | Line 8: | ||

which the developer may wish to hide. | which the developer may wish to hide. | ||

- | GAMS has several utilities, which aid in [[conversion_of_confidential_models_for_submission_to_gams_support#converting_a_single_model_instance_to_scalar_format|conversion into scalar format and the removal of confidential information]]. In particular, [[http://www.gams.com/solvers/solvers.htm#CONVERT|GAMS/CONVERT]] is a utility which transforms a GAMS model instance into formats used by other modeling and solution systems. GAMS/CONVERT is designed to achieve the following goals: | + | GAMS has several utilities, which aid in [[conversion_of_confidential_models_for_submission_to_gams_support#converting_a_single_model_instance_to_scalar_format|conversion into scalar format and the removal of confidential information]]. In particular, [[https://www.gams.com/latest/docs/S_CONVERT.html|GAMS/CONVERT]] is a utility which transforms a GAMS model instance into formats used by other modeling and solution systems. GAMS/CONVERT is designed to achieve the following goals: |

* Permit users to convert a confidential model into GAMS scalar format so that any identifiable structure is removed. It can then be passed on to others for investigation without confidentiality being lost. | * Permit users to convert a confidential model into GAMS scalar format so that any identifiable structure is removed. It can then be passed on to others for investigation without confidentiality being lost. | ||

* A way of sharing GAMS test problems for use with other modeling systems or solvers. | * A way of sharing GAMS test problems for use with other modeling systems or solvers. | ||

GAMS/CONVERT comes free of charge with any licensed GAMS system. | GAMS/CONVERT comes free of charge with any licensed GAMS system. | ||

- | ===== Converting a Single Model Instance to Scalar Format ===== | + | ===== Simple Conversion ===== |

- | ==== Simple Conversion ==== | + | |

The GAMS/CONVERT utility can transform a **single model instance** (from a solve statement) into scalar format. The scalar format removes all confidential information (data and identifiable model data structures). To translate a model into a scalar format removing any identifiable modeling constructs, enter: | The GAMS/CONVERT utility can transform a **single model instance** (from a solve statement) into scalar format. The scalar format removes all confidential information (data and identifiable model data structures). To translate a model into a scalar format removing any identifiable modeling constructs, enter: | ||

gams mymodel.gms [modeltype]=convert | gams mymodel.gms [modeltype]=convert | ||

- | where [modeltype] is the model type used (LP, NLP, MIP, etc.). This will generate a scalar model called gams.gms which can be submitted to GAMS support or others without divulging any confidential information. Below is an example output generated from the trnsport model of the [[http://www.gams.com/modlib/modlib.htm|GAMS model library]] using the default settings: | + | where [modeltype] is the model type used (LP, NLP, MIP, etc.). If you have hard coded the solver inside your GAMS model via an option statement like ''option LP=bdmlp;'' or need to solve other models before the model instance you want to convert you should not set the ''[modeltype]=convert'' command line option, but add the run time option ''option [modeltype]=convert;'' in front of the solve statement of the model instance you want to convert. This will generate a scalar model called gams.gms which can be submitted to GAMS support or others without divulging any confidential information. Below is an example output generated from the trnsport model of the [[http://www.gams.com/modlib/modlib.htm|GAMS model library]] using the default settings: |

<code> | <code> | ||

* LP written by GAMS Convert at 02/08/08 11:45:21 | * LP written by GAMS Convert at 02/08/08 11:45:21 | ||

Line 78: | Line 77: | ||

- | ==== Customized Scalar Model Output ==== | + | ===== Customized Scalar Model Output ===== |

- | CONVERT allows customized scalar model output by making use of options. Please consult the CONVERT options in the [[http://www.gams.com/solvers/solvers.htm#CONVERT|CONVERT user guide]] for details. | + | CONVERT allows customized scalar model output by making use of options. Please consult the CONVERT options in the [[https://www.gams.com/latest/docs/S_CONVERT.html|CONVERT user guide]] for details. |

To do so, the user must make a solver option file called convert.opt (or similarly using the GAMS option file naming conventions). As usual, the user must tell GAMS to use this option file, either by specifying | To do so, the user must make a solver option file called convert.opt (or similarly using the GAMS option file naming conventions). As usual, the user must tell GAMS to use this option file, either by specifying | ||

gams mymodel.gms [modeltype]=convert optfile=1 | gams mymodel.gms [modeltype]=convert optfile=1 | ||

from the command line, or | from the command line, or | ||

- | mymodel.optfile = 1; | + | mymodel.optfile = 1; option [modeltype]=convert; |

before the solve statement in the model. | before the solve statement in the model. | ||

- | === Custom scalar model name === | + | ===== Custom scalar model name ===== |

The default scalar model created is called ''gams.gms''. In order to generate a scalar model with a different name, specify''gams mymodel.gms'' | The default scalar model created is called ''gams.gms''. In order to generate a scalar model with a different name, specify''gams mymodel.gms'' | ||

in the ''convert.opt'' option file. The resulting output file will be called ''mymodel.gms''. | in the ''convert.opt'' option file. The resulting output file will be called ''mymodel.gms''. | ||

- | === Terminate GAMS after solve === | + | ===== Terminate GAMS after solve ===== |

Models may consist of several solves, whereas the user may wish to obtain the scalar model only from a single particular solve. The CONVERT option ''terminate'' causes GAMS to abort once the solve is complete. To do so, specify ''terminate'' in the ''convert.opt'' option file. GAMS will then terminate after the solve (and resulting scalar model conversion) is completed. Note that it may be necessary to specify different solvers before previous solves and then specify CONVERT as the solver only for the particular solve for which one wishes to obtain a scalar model. | Models may consist of several solves, whereas the user may wish to obtain the scalar model only from a single particular solve. The CONVERT option ''terminate'' causes GAMS to abort once the solve is complete. To do so, specify ''terminate'' in the ''convert.opt'' option file. GAMS will then terminate after the solve (and resulting scalar model conversion) is completed. Note that it may be necessary to specify different solvers before previous solves and then specify CONVERT as the solver only for the particular solve for which one wishes to obtain a scalar model. | ||

- | === Renaming the objective variable in the scalar model === | + | |

+ | ===== Renaming the objective variable in the scalar model ===== | ||

By default, the scalar variable is called x1, x2, x3, or similar. If the user wishes to rename the objective variable to something more identifiable, the user can do so by specifying ''ObjVar myobj'' in the ''convert.opt'' option file. The resulting objective variable will then be called ''myobj''. If the user only specifies ''ObjVa''r, the default is ''objvar''. | By default, the scalar variable is called x1, x2, x3, or similar. If the user wishes to rename the objective variable to something more identifiable, the user can do so by specifying ''ObjVar myobj'' in the ''convert.opt'' option file. The resulting objective variable will then be called ''myobj''. If the user only specifies ''ObjVa''r, the default is ''objvar''. | ||

- | === Mapping scalar data structure names to original model names === | + | ===== Mapping scalar data structure names to original model names ===== |

- | The scalar model uses data structures called ''x1, x2, x3,...'' for variables and ''eq1, eq2, eq3,...'' for equations. The user may wish to know how scalar data structures are mapped to the original variable and equation names. For example, GAMS support may identify infeasibilities in a particular scalar equation, which the user needs to identify in the original (non-scalar) model. To do so, CONVERT has an option called Dict. Specifying ''Dict mydict.txt'' in the ''convert.opt'' option file will generate a dictionary file called ''mydict.txt'' containing the mapping information. If only ''Dict'' is specified, the default filename is ''dict.txt''. A sample dictionary file, obtained from running CONVERT on the transportation model ([[http://www.gams.com/modlib/libhtml/trnsport.htm|trnsport.gms]]) is given below: | + | The scalar model uses data structures called ''x1, x2, x3,...'' for variables and ''eq1, eq2, eq3,...'' for equations. The user may wish to know how scalar data structures are mapped to the original variable and equation names. For example, GAMS support may identify infeasibilities in a particular scalar equation, which the user needs to identify in the original (non-scalar) model. To do so, CONVERT has an option called Dict. Specifying ''Dict mydict.txt'' in the ''convert.opt'' option file will generate a dictionary file called ''mydict.txt'' containing the mapping information. If only ''Dict'' is specified, the default file name is ''dict.txt''. A sample dictionary file, obtained from running CONVERT on the transportation model ([[http://www.gams.com/modlib/libhtml/trnsport.htm|trnsport.gms]]) is given below: |

<code> | <code> | ||

LP written by GAMS Convert at 02/08/08 11:56:03 | LP written by GAMS Convert at 02/08/08 11:56:03 | ||

Line 130: | Line 130: | ||

x7 z</code> | x7 z</code> | ||

+ | ===== Non-disclosure agreement ===== | ||

+ | We are happy to sign a non-disclosure agreement (NDA), also known as a confidentiality agreement (CA), in case this is required. |

IMPRESSUM / LEGAL NOTICE
PRIVACY POLICY
conversion_of_confidential_models_for_submission_to_gams_support.1303310891.txt.gz · Last modified: 2011/04/20 16:48 by support