Skip to content

Conversation

@aliceb-nv
Copy link
Contributor

The MIP codepath assumes the current problem possesses a non-zero number of integer variables.
This is normally never the case as LP problems are directed to the LP codepath, however some trivial MIP instances lose their integer variables after presolve.

In those cases the problem is solved at the root relaxation, this PR simply fixes assertions and checks to ensure such instances don't trigger failures on the MIP heuristics side.

Also fixes an issue where initial solutions were scaled regardless of the mip scaling setting

Fixes #233

@aliceb-nv aliceb-nv added this to the 25.08 milestone Jul 25, 2025
@aliceb-nv aliceb-nv requested a review from a team as a code owner July 25, 2025 09:16
@aliceb-nv aliceb-nv added bug Something isn't working non-breaking Introduces a non-breaking change labels Jul 25, 2025
@aliceb-nv aliceb-nv requested review from hlinsen and kaatish July 25, 2025 09:16
Copy link
Contributor

@akifcorduk akifcorduk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would not run MIP at all if the number of integers is zero but run LP with it and exit. For now you could just run PDLP.

robertmaynard and others added 5 commits July 28, 2025 09:18
The helm chart adds an option to users to deploy cuOpt in kubernetes with basic setting.  Users can always modify or create a helm chart as per their requirement.

## Issue
closes #124

Authors:
  - Ramakrishnap (https://github.com/rgsl888prabhu)

Approvers:
  - Trevor McKay (https://github.com/tmckayus)

URL: #224
Adds workflow for container build, test and push for nightly and release.

Nightly container would have the tag for example 25.8.0a-cuda12.8-py3.12

And these will be published to https://hub.docker.com/r/nvidia/cuopt/tags and ngc internal registry.

This PR also removes several unused workflows and also update license header.


## Issue
closes #123

Authors:
  - Ramakrishnap (https://github.com/rgsl888prabhu)

Approvers:
  - Trevor McKay (https://github.com/tmckayus)
  - Gil Forsyth (https://github.com/gforsyth)

URL: #180
@aliceb-nv aliceb-nv requested review from a team as code owners July 28, 2025 09:18
@aliceb-nv aliceb-nv requested review from Iroy30 and bdice July 28, 2025 09:18
@aliceb-nv aliceb-nv removed request for a team, Iroy30 and bdice July 28, 2025 09:20
@rgsl888prabhu
Copy link
Collaborator

@kaatish @hlinsen May I get your review on this PR ?

settings.time_limit = timer_.remaining_time();
settings.method = method_t::Concurrent;

auto opt_sol = solve_lp_with_method<i_t, f_t>(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Calling LP with solve_lp_with_method instead of solve_lp means we would not get the initial LP problem checks and presolve being added in #234.
Should we use it instead? the rest looks good to me!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also think we should be calling solve_lp and pass down the corresponding settings to use concurrent unless I missed something

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Problem checks should be superfluous as they're already performed on the presolved problem. Additionally, the checks in solve_lp are only done on the original problem structure (which has already been checked at the time of calling solve_mip)
solve_lp requires passing either a mps_data_model or the original optimization_problem_t instead of the presolved problem, I used solve_lp_with_method to avoid making changes to solve_lp. Do you think I should add an overload instead?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think another overload would over complexify things at this point. I prefer sticking with this approach. What we could do is move the try/catch and presolve in solve_lp_with_method in some other PR.

@rgsl888prabhu
Copy link
Collaborator

Lets try to merge this PR, since few other PRs are waiting on this.

Copy link
Contributor

@hlinsen hlinsen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks Alice!

settings.time_limit = timer_.remaining_time();
settings.method = method_t::Concurrent;

auto opt_sol = solve_lp_with_method<i_t, f_t>(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think another overload would over complexify things at this point. I prefer sticking with this approach. What we could do is move the try/catch and presolve in solve_lp_with_method in some other PR.

@aliceb-nv
Copy link
Contributor Author

/merge

@rapids-bot rapids-bot bot merged commit e33e73c into branch-25.08 Jul 30, 2025
73 checks passed
@rgsl888prabhu
Copy link
Collaborator

Thank you @aliceb-nv @hlinsen

rapids-bot bot pushed a commit that referenced this pull request Jul 30, 2025
This is a simple smoketest to look for breakage and any abnormal behavior with respect to runtime from cuopt Python API changes. It does not do any exhaustive performance testing or building.

depends on #235

Authors:
  - Trevor McKay (https://github.com/tmckayus)
  - James Lamb (https://github.com/jameslamb)
  - Ramakrishnap (https://github.com/rgsl888prabhu)

Approvers:
  - James Lamb (https://github.com/jameslamb)

URL: #199
@rgsl888prabhu rgsl888prabhu deleted the no-int-var-fix branch October 29, 2025 16:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working non-breaking Introduces a non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] In assert mode MIP fails with too many variable error

8 participants