Skip to content

Conversation

@nHackel
Copy link
Contributor

@nHackel nHackel commented Apr 11, 2024

This PR adds the S keyword to the opRestriction constructor. This fixes #323.

Since the operator has no type information of the storage type for a default cause of S = Vector{T} as other operators ahve, I've opted to give him a default of nothing. If S is nothing the normal operator is called, which will have a storage type of Vector{Int64}.

I did not add a opRestriction(...; kwargs...) for the constructors which fall back on other operators, since at a quick glance I didn't see such a pattern used in this package.

@github-actions
Copy link
Contributor

Package name latest stable
CaNNOLeS.jl
DCISolver.jl
FletcherPenaltySolver.jl
JSOSolvers.jl
Krylov.jl
NLPModels.jl
NLPModelsModifiers.jl
PROPACK.jl
Percival.jl
QuadraticModels.jl
SolverTools.jl

Copy link
Member

@geoffroyleconte geoffroyleconte left a comment

Choose a reason for hiding this comment

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

Thank you!

Copy link
Member

@dpo dpo left a comment

Choose a reason for hiding this comment

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

This looks good, thank you!

For my own information, what should S be in your example in #323?

@dpo dpo merged commit ee2af5b into JuliaSmoothOptimizers:main Apr 20, 2024
@nHackel
Copy link
Contributor Author

nHackel commented Apr 30, 2024

@dpo in that case it should have been a CuArray{Float32, 1, CUDA.Mem.DeviceBuffer}. The last parameter seems to describe the "memory"-type of the array and it might change in future version of CUDA if I understood their Docs/plans correctly

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.

Missing S keyword for opRestriction

3 participants