[BUG] MIP with default presolve returns OPTIMAL with x = 0 for `-1e6 * x <= -7`, x binary (row violated by 7)
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 42/100
Direzione di ricerca
Start by reproducing the single binary-variable MPS case in the Python script, comparing default presolve with presolve disabled and a tighter integrality tolerance. The report points to PaPILO's hard-coded feasibility tolerance (#1502) as a possible lead, but says the cause has not been traced. Done means presolve no longer returns an infeasible point as OPTIMAL or as an incumbent; verify the reported case and the MIPLIB cdma rows against an independent feasibility check.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Drafted by Claude Code (an AI agent) for Berk Orbay, who reviewed it before posting.
Describe the bug
A binary x with the single row -1e6 * x <= -7 must be 1. With presolve on (the default, 1 or 2), cuOpt 26.10.0
returns OPTIMAL with x = 0, which violates the row by 7. That is far above any feasibility tolerance (default
mip_absolute_tolerance is 1e-6). Lowering mip_integrality_tolerance to 1e-9 does not change it. With
presolve = 0 and mip_integrality_tolerance = 1e-9, the result is correct (x = 1).
The result flips where the implied bound 7/a crosses 1e-5: wrong at a = 7e5 (bound 1.0e-5), right at a = 5e5
(bound 1.4e-5). That value matches PaPILO's hard-coded feastol = 1e-5 (#1502), so the cause may be the same line.
The consequence is different, though: not a 1e-5-level violation, but a row violated by its whole right-hand side,
on the default MIP path, and reported as OPTIMAL. We have not traced it in the source.
Minimal reproduction (Python; script below)
minimise x x binary
s.t. -a * x <= -7 (x >= 7/a, so x must be 1)
| a | implied bound 7/a | cuOpt 26.10.0, default settings | HiGHS 1.15.1 | SCIP 10.0 |
|---|---|---|---|---|
| 10, 1e3, 1e5, 2e5, 5e5 | 0.7 … 1.4e-5 | OPTIMAL, x = 1 | x = 1 | — |
| 7e5 | 1.0e-5 | OPTIMAL, x = 0 | x = 1 | x = 1 |
| 1e6, 1.2e6, 1e7, 1e9 | 7e-6 … 7e-9 | OPTIMAL, x = 0 | x = 1 | x = 1 (1e6, 1e9) |
For a = 1e6:
| presolve | mip_integrality_tolerance | cuOpt 26.10.0 |
|---|---|---|
| default | default (1e-5) | OPTIMAL, x = 0 (row violated by 7) |
| 1 | default | OPTIMAL, x = 0 |
| 2 | default | OPTIMAL, x = 0 |
| default, 1, 2 | 1e-9 | OPTIMAL, x = 0 |
| 0 | default | OPTIMAL, x = 7e-6 (integral within the default tolerance; expected, not part of this report) |
| 0 | 1e-9 | OPTIMAL, x = 1 (correct) |
Where we met it: MIPLIB 2017 cdma. It has five singleton rows -1.2e6 * x <= rhs on binaries, with rhs −7, −11,
−11, −12 and −13, so implied bounds 5.8e-6, 9.2e-6, 9.2e-6, 1.0e-5 and 1.08e-5.
- Callback incumbents. In three runs of cuOpt alone (5 threads, 120 s and 2 × 300 s), 12 of the 22 incumbents
reported through the MIP callback fail an independent check (HiGHS-read model, 1e-6). Every violated row is one of
the −7, −11 and −12 rows, with x = 0. The −13 row (bound 1.08e-5) is never violated. - Final solution. The final solution returned by
Solve()is infeasible in the same way: default settings,
120 s, objective −1.24e16, 2 rows violated. Withpresolve = 0andmip_integrality_tolerance = 1e-9, every
incumbent and the final solution pass the check, at a weaker objective (−5.56e14). - Objective gap. The infeasible points look up to 3.3× better than cuOpt's own best valid incumbent (−1.70e16 vs
−5.19e15). They are not better than the best known feasible value (−2.48e16).
Expected behavior
A point that violates a model row by more than the feasibility tolerance should not be returned as OPTIMAL (or
as an incumbent). A guess at the fix: when presolve derives a bound for an integer variable, it should round it in
the integer sense, lb = ceil(7e-6 - int_tol) = 1 here, rather than treat it as 0 within a continuous tolerance.
Environment
cuOpt 26.10.0 (cuopt-cu13, Python 3.12), NVIDIA DGX Spark (GB10, aarch64), driver 580.173.02, CUDA 13.0, Ubuntu
24.04. Not tested on 26.10.1, which moved the PaPILO pin.
repro script (Python, cuOpt 26.10.0)
import os, tempfile
import numpy as np
from cuopt.linear_programming import ParseMps, Solve, SolverSettings
def mps(a: float) -> str:
return f"""NAME singleton
ROWS
N obj
L r1
COLUMNS
MARKER 'MARKER' 'INTORG'
x obj 1.0 r1 {-a!r}
MARKER 'MARKER' 'INTEND'
RHS
rhs r1 -7.0
BOUNDS
UP bnd x 1.0
ENDATA
"""
def run(path, presolve=None, int_tol=None):
s = SolverSettings()
s.set_parameter("time_limit", 10.0)
if presolve is not None:
s.set_parameter("presolve", presolve)
if int_tol is not None:
s.set_parameter("mip_integrality_tolerance", int_tol)
sol = Solve(ParseMps(path), s)
return int(sol.get_termination_status()), float(sol.get_primal_objective()), list(np.asarray(sol.get_primal_solution()))
with tempfile.TemporaryDirectory() as d:
for a in [10.0, 1e3, 1e5, 2e5, 5e5, 7e5, 1e6, 1.2e6, 1e7, 1e9]:
p = os.path.join(d, "s.mps"); open(p, "w").write(mps(a))
print(f"a={a:g} x>={7/a:.2e}", run(p))
p = os.path.join(d, "s.mps"); open(p, "w").write(mps(1e6))
for pre, itol in ((None, None), (1, None), (2, None), (0, None), (None, 1e-9), (0, 1e-9)):
print("a=1e6 presolve", pre, "int_tol", itol, run(p, pre, itol))
- Lingua principale
- Cuda
- Stelle
- 1.1k
- Fork
- 266
- Merge medio
- 1g 23h
- PR unite (30g)
- 54
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di NVIDIA/cuopt
-
[BUG] cuDSS 1.0 rejects libcudss_mtlayer_cuopt.so (status = 3): missing cudssThreadingGetPropertyAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
[BUG] Python: Problem.addConstraint accepts the same Constraint twiceForse già presa @pcbeingused333 l’ha presa 16 giorni fa. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
[BUG] Fully presolved MILP returns FeasibleFound with an infinite bound since 26.10.0Forse già presa @j3soon l’ha presa 7 giorni fa. Apertabug
Difficoltà 4/5 3-5 giorni Idoneità per principianti 15/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di NVIDIA/cuopt
Issue simili
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
OpenSAK-Org/OpenSAK#1418 ·
I maintainer di solito rispondono entro 1 giorno
-
bug triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
envoyproxy/envoy#49711 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
substrait-io/substrait#1355 ·
I maintainer di solito rispondono entro 2 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
genfeedai/genfeed.ai#11820 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
nf-osi/nf-metadata-dictionary#1078 ·
I maintainer di solito rispondono entro 2 giorni