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

Prepare CUTEst.jl for single and quadruple precision #353

Merged
merged 1 commit into from
Aug 19, 2024

Conversation

amontoison
Copy link
Member

@amontoison amontoison commented Aug 18, 2024

Should be merged after #344, #349, #350, #351 and #352

@amontoison amontoison requested a review from tmigot August 18, 2024 21:33
Copy link

codecov bot commented Aug 18, 2024

Codecov Report

Attention: Patch coverage is 26.51007% with 219 lines in your changes missing coverage. Please review.

Project coverage is 60.66%. Comparing base (f2ad6a4) to head (22d8487).
Report is 31 commits behind head on main.

Files Patch % Lines
src/libcutest.jl 20.36% 219 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #353       +/-   ##
===========================================
- Coverage   89.11%   60.66%   -28.46%     
===========================================
  Files           5        8        +3     
  Lines         790     1388      +598     
===========================================
+ Hits          704      842      +138     
- Misses         86      546      +460     

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

@amontoison amontoison changed the title Prepare CUTEst.jl for single precision Prepare CUTEst.jl for single and quadruple precision Aug 19, 2024
Copy link
Member

@tmigot tmigot left a comment

Choose a reason for hiding this comment

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

Thanks @amontoison, looking good. Just some small comments

Comment on lines +13 to +18
global cutest_instances_single = 0
global cutest_instances_double = 0
global cutest_instances_quadruple = 0
global cutest_lib_single = C_NULL
global cutest_lib_double = C_NULL
global cutest_lib_quadruple = C_NULL
Copy link
Member

Choose a reason for hiding this comment

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

Maybe we should at some point create a structure for this? That could be an issue with the tag good first issue.

Copy link
Member Author

Choose a reason for hiding this comment

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

I added a SIF demuxer in the latest version of CUTEst such that we don't need anymore to update the global variables.
The issue is that package was not updated since long time we need many modifications if we want to easily upgrade it.

src/model.jl Show resolved Hide resolved
@@ -226,7 +226,7 @@ function CUTEstModel(
nnzj = nnzj[] |> Int
nnzh = nnzh[] |> Int

work = Vector{Int32}(undef, ncon)
work = Vector{Float64}(undef, ncon)
Copy link
Member

Choose a reason for hiding this comment

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

Could you add a one-line comment for this vector?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think we should add two vectors in the structure (one of size nvar and another of size ncon). We need these kind of buffer / workspace for a lot of CUTEst routines.

@amontoison amontoison force-pushed the multiprecision branch 2 times, most recently from b6ddce9 to e8ec19f Compare August 19, 2024 13:04
@amontoison amontoison merged commit 9e3cade into JuliaSmoothOptimizers:main Aug 19, 2024
7 of 13 checks passed
@amontoison amontoison deleted the multiprecision branch August 19, 2024 13:07
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.

2 participants