Page 1 of 1

Checkpoint file {}/_gams_py_gc1.g00 does not exist

Posted: Sat May 13, 2023 8:51 pm
by DanielJimenezAvalo
Hello,

I'm trying to execute gams sequentially from multiple scenarios, where the results of the previous scenario are used in the next execution, for that, I'm using the gams transfer API. The first scenario executes correctly, but the next scenario gives me this error:

raise gams.control.workspace.GamsException("Checkpoint file " + checkpoint._checkpoint_file_name + " does not exist")
gams.control.workspace.GamsException: Checkpoint file {dir}\_gams_py_gcp1.g00 does not exist

I know these files are generated during the execution of the checkpoint (GamsWorkspace().add_checkpoint()) before the execution of the simulation ({MODEL}.run()), nevertheless, the error should appear at the execution of the first scenario but doesn't happen.

Re: Checkpoint file {}/_gams_py_gc1.g00 does not exist

Posted: Sun May 14, 2023 8:32 am
by bussieck
If you want some help, you need to send something one can reproduce.

-Michael

Re: Checkpoint file {}/_gams_py_gc1.g00 does not exist

Posted: Tue May 16, 2023 7:41 pm
by DanielJimenezAvalo
thanks for the reply, I solved the problem using this:

#create a checkpoint in any iteration
check_point=ws.add_checkpoint()

#use the options of the models and run the model until the checkpoint
transfer_model.run(gams_options=opt,checkpoint=check_point)

#add the run execution of the model point to the checkpoint
transfer_model = ws.add_job_from_string(gams_source="solve multibenders2a using LP minimizing Z;", checkpoint=check_point)

transfer_model.run(gams_options=opt,checkpoint=check_point)