-
Notifications
You must be signed in to change notification settings - Fork 0
Description
When a GAMS problem is passed as a MIP with no integer variables, an error is returned when trying to obtain the solution bound.
For background information: Our problem formulation sometimes contains integer variables and sometimes only continuous variables, depending on the input data. To avoid additional control workflow, we always pass the problem as an MIP, which the solver correctly identifies either as LP or MIP. This also seems to work correctly for cuOpt on the solver side, but causes issues with the GAMS cuoptlink, which expects an MIP return.
Ideally GAMS would recognize that a LP was solved and continue or at least provide a more meaningful error message.
Output for gams trnsport.gms mip=cuopt with changed solve statement from LP to MIP:
System information: 72 physical cores and 574 Gb physical memory detected
GAMS 52.3.0 Copyright (C) 1987-2025 GAMS Development. All rights reserved
--- Starting compilation
--- trnsport.gms(69) 3 Mb
--- Starting execution: elapsed 0:00:00.007
--- trnsport.gms(65) 4 Mb
--- Generating MIP model transport
--- trnsport.gms(67) 4 Mb
--- 6 rows 7 columns 19 non-zeroes
--- Range statistics (absolute non-zero finite values)
--- RHS [min, max] : [ 2.750E+02, 6.000E+02] - Zero values observed as well
--- Bound [min, max] : [ NA, NA] - Zero values observed as well
--- Matrix [min, max] : [ 1.260E-01, 1.000E+00]
--- Executing CUOPT (Solvelink=2): elapsed 0:00:00.011
GAMS/cuOpt link was built against cuOpt version: 25.12.00, git hash: d97ff6b4762f9df4459534ccf56d70c8e172bc81
Reading parameter(s) from "cuopt.opt"
>> method 1
>> relative_gap_tolerance 1e-5
Finished reading from "cuopt.opt"
Setting parameter mip_absolute_gap to 0.000000e+00
Setting parameter mip_relative_gap to 1.000000e-04
Setting parameter method to 1
Setting parameter relative_gap_tolerance to 1.000000e-05
Setting parameter log_file to 225a/cuopt.dat
cuOpt version: 25.12.0, git hash: d97ff6b, host arch: aarch64, device archs: 70-real,75-real,80-real,86-real,90a-real,100f-real,120a-real,120
CPU: Unknown, threads (physical/logical): 1/72, RAM: 551.36 GiB
CUDA 12.9, device: NVIDIA GH200 480GB (ID 0), VRAM: 95.00 GiB
CUDA device UUID: f8df1b1d-436e-7097-c135-ac3336f6e109
Solving a problem with 5 constraints, 6 variables (0 integers), and 12 nonzeros
Problem scaling:
Objective coefficents range: [1e-01, 2e-01]
Constraint matrix coefficients range: [1e+00, 1e+00]
Constraint rhs / bounds range: [0e+00, 6e+02]
Variable bounds range: [0e+00, 0e+00]
Third-party presolve is disabled, skipping
Objective offset 0.000000 scaling_factor 1.000000
Iter Primal Obj. Dual Obj. Gap Primal Res. Dual Res. Time
0 +0.00000000e+00 +0.00000000e+00 0.00e+00 5.21e+02 4.39e-01 0.110s
430 +1.53677030e+02 +1.53675629e+02 1.40e-03 0.00e+00 5.13e-06 0.140s
LP Solver status: Optimal
Primal objective: +1.53677030e+02
Dual objective: +1.53675629e+02
Duality gap (abs/rel): +1.40e-03 / +4.54e-06
Primal infeasibility (abs/rel): +0.00e+00 / +0.00e+00
Dual infeasibility (abs/rel): +5.13e-06 / +3.56e-06
PDLP finished
Status: Optimal Objective: 1.53677030e+02 Iterations: 430 Time: 0.084s, Total time 0.142s
Error getting solution bound: 1
--- Reading solution for model transport
--- Executing after solve: elapsed 0:00:01.238
--- trnsport.gms(69) 4 Mb
*** Status: Normal completion
--- Job trnsport.gms Stop 01/16/26 13:27:53 elapsed 0:00:01.242