-
Notifications
You must be signed in to change notification settings - Fork 112
Closed
Labels
bugSomething isn't workingSomething isn't working
Milestone
Description
Describe the bug
The objective should evaluate to a non-nan value.
Steps/Code to reproduce bug
from cuopt.linear_programming import DataModel, Solve, SolverSettings
from cuopt_mps_parser import ParseMps
dm = ParseMps("Bug1.mps")
print("OBJECTIVE COEFFICIENTS: ", dm.get_objective_coefficients())
sol = Solve(dm)
print("PRIMAL SOLUTION: ", sol.get_primal_solution())
print("PRIMAL OBJECTIVE: ", sol.get_primal_objective())
MPS File: ObjectiveBug.mps.zip
Output:
OBJECTIVE COEFFICIENTS: [1. 1. 1. 1. 1. 1. 0. 0. 0. 0. 0. 0.]
Solving a problem with 6 constraints 12 variables (0 integers) and 6 nonzeros
Objective offset 0.000000 scaling_factor 1.000000
Running concurrent
Dual simplex finished in 0.00 seconds
Iter Primal Obj. Dual Obj. Gap Primal Res. Dual Res. Time
0 +0.00000000e+00 +0.00000000e+00 0.00e+00 2.00e+00 2.45e+00 0.013s
PDLP finished
Concurrent time: 0.015s
Solved with dual simplex
Status: Optimal Objective: -nan Iterations: 6 Time: 0.015s
PRIMAL SOLUTION: [ -0. 1. -0. 1. 1. 1. -inf -inf -inf -inf -inf -inf]
PRIMAL OBJECTIVE: nan
Expected behavior
Objective value should be 4.0 instead of nan
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working