Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UPD: update to the NonlinearExpr syntax of JuMP v1.15 #454

Merged
merged 2 commits into from
Sep 18, 2024

Conversation

odow
Copy link
Contributor

@odow odow commented Jan 30, 2024

Closes #453

The tests haven't finished running locally, so there might be some more changes needed, but this is a start. I'll comment in-line about some formatting changes we could do here, or in a separate PR.

src/core/base.jl Show resolved Hide resolved
Copy link

codecov bot commented Jan 30, 2024

Codecov Report

Attention: Patch coverage is 80.61798% with 69 lines in your changes are missing coverage. Please review.

Project coverage is 73.64%. Comparing base (80d6178) to head (c968b1c).
Report is 2 commits behind head on main.

❗ Current head c968b1c differs from pull request most recent head a6b5224. Consider uploading reports for the commit a6b5224 to get more accurate results

Files Patch % Lines
src/form/acp.jl 64.64% 35 Missing ⚠️
src/core/objective.jl 41.66% 14 Missing ⚠️
src/form/en_acr.jl 84.61% 8 Missing ⚠️
src/form/acr.jl 93.33% 4 Missing ⚠️
src/form/bf_fbs.jl 0.00% 2 Missing ⚠️
src/form/fotp.jl 0.00% 2 Missing ⚠️
src/form/fotr.jl 0.00% 2 Missing ⚠️
src/form/ivr.jl 96.42% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #454      +/-   ##
==========================================
- Coverage   75.01%   73.64%   -1.37%     
==========================================
  Files          73       71       -2     
  Lines       16541    16264     -277     
==========================================
- Hits        12408    11978     -430     
- Misses       4133     4286     +153     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@odow
Copy link
Contributor Author

odow commented Jan 31, 2024

@ccoffrin (or anyone): are the failing tests global solutions (and there's a bug somewhere)? Or are these local minima, and by changing the order of constraints etc we now find new solutions?

@ccoffrin
Copy link
Member

Good question. I am not that familiar with how stable the tests are in terms of local minima. The failing tests do appear to be consolidated in the non-convex formulations, so it is a reasonable hypothesis. We will need one of the primary developers to look into it to assess.

@odow
Copy link
Contributor Author

odow commented May 7, 2024

Hey @pseudocubic any chance you could take a look at this? Or point me in the right direction?

@pseudocubic
Copy link
Collaborator

@odow we have been looking at this but still haven't identified an obvious pattern in the failing tests, and based on the changes in PMD and JuMP 1.15 don't understand what would have caused all the failures we're seeing.

@pseudocubic pseudocubic mentioned this pull request May 8, 2024
@odow odow closed this Sep 12, 2024
@odow odow reopened this Sep 12, 2024
Project.toml Outdated Show resolved Hide resolved
@odow
Copy link
Contributor Author

odow commented Sep 13, 2024

Now we're getting somewhere. These two failures just look flakey? One looks like a tolerance issue, and the other is Ipopt not succeeding.

test/transformer.jl Outdated Show resolved Hide resolved
@ccoffrin
Copy link
Member

Given all tests are passing, is there any reason not to merge and tag?

@odow
Copy link
Contributor Author

odow commented Sep 17, 2024

From my side, I'm good.

Copy link
Collaborator

@pseudocubic pseudocubic left a comment

Choose a reason for hiding this comment

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

I have re-reviewed the PR from scratch, and left a comment on some lines added to Project.toml.

Also, please add an update to the CHANGELOG

Otherwise, it looks good, thanks for helping us to track down the issue in JuMP and make these changes to PMD!

Project.toml Outdated
Comment on lines 26 to 39
Dates = "1.6"
FilePaths = "0.8.3"
Glob = "1.3"
Graphs = "1"
InfrastructureModels = "0.7.3, 0.7.5"
Ipopt = "0.9, 1.0.2, 1.1"
Ipopt = "1"
JSON = "0.18, 0.19, 0.20, 0.21"
JuMP = "0.22, 0.23, 1"
JuMP = "1.23.2"
LoggingExtras = "0.4.7, 1"
PolyhedralRelaxations = "0.3.5"
SCS = "0.9, 1.0, 1.1"
SparseArrays = "1.6"
SpecialFunctions = "2"
Test = "1.6"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is there a reason Dates, SparseArrays and Test were added to compat? My impression was that these don't need to be explicitly listed because of the julia compat entry.

@odow
Copy link
Contributor Author

odow commented Sep 17, 2024

I've added the CHANGELOG entry.

For the compat bounds: future versions of Julia are going to decouple stdlib versions from the Julia version, so best practice is to add compat bounds. But there was a bug in Julia 1.6 that prevented them from enforcing this rule all packages at registration time.

I've removed for now, but in some future version, we'll likely need to add them back. (Probably when/if you set julia = "1.10".)

@pseudocubic pseudocubic merged commit 68d7855 into lanl-ansi:main Sep 18, 2024
10 checks passed
@pseudocubic
Copy link
Collaborator

Looks good! Thanks for the info about stdlib versions getting decoupled, I didn't know that, so I'll keep an eye out in the future.

Thanks again for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update to JuMP NonlinearExpr syntax
3 participants