Save and restart to isolate problem areas

Top  Previous  Next

Cases involving large data sets must be run.  I work with several models that take hours to run.  When I wish to add or verify code in a relatively small segment, an important strategy is to isolate it.

This permits repair and investigation without having to freshly input data, do initial calculations and solve.  I do this using save and restart files.  Consider the following example.

 

rem GAMS ALLOFIT.gms pw=80 s=.\t\save1

rem GAMS ASMMODEL.gms pw=80 r=.\t\save1 s=.\t\save2

rem GAMS ASMSOLVF.gms r=.\t\save2 s=.\t\save3

GAMS ASMREPT.gms pw=80 r=.\t\save3

 

The last command in the sequence involving asmrept.gms is executing report writer code.  When I wish to make changes in the report writer code I often will run it by itself from the saved files or will even just run a smaller file containing the few instructions I wish to focus on.