[BUG] MIP with default presolve returns OPTIMAL with x = 0 for `-1e6 * x <= -7`, x binary (row violated by 7)
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 42/100
Hướng nghiên cứu
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.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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))
- Ngôn ngữ chính
- Cuda
- Star
- 1.1k
- Fork
- 266
- Merge trung bình
- 1 ngày 23 giờ
- Pull request đã merge (30 ngày)
- 54
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của NVIDIA/cuopt
-
[BUG] cuDSS 1.0 rejects libcudss_mtlayer_cuopt.so (status = 3): missing cudssThreadingGetPropertyĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[BUG] Python: Problem.addConstraint accepts the same Constraint twiceCó thể đã có người làm @pcbeingused333 đã nhận 16 ngày trước. Đang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
[BUG] Fully presolved MILP returns FeasibleFound with an infinite bound since 26.10.0Có thể đã có người làm @j3soon đã nhận 7 ngày trước. Đang mởbug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 15/100
Maintainer thường phản hồi trong vòng 1 ngày
Issue tương tự
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 82/100
BCStudentSoftwareDevTeam/cas#491 ·
Maintainer thường phản hồi trong vòng 8 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
OpenSAK-Org/OpenSAK#1418 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
bug triage
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
envoyproxy/envoy#49711 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
substrait-io/substrait#1355 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
genfeedai/genfeed.ai#11820 ·
Maintainer thường phản hồi trong vòng 1 ngày