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

fix: merge_strategy() is an instance, not a type #164

Merged
merged 3 commits into from
Dec 28, 2022

Conversation

kalmarek
Copy link
Contributor

@kalmarek kalmarek commented Nov 23, 2022

This is the error I got:

ERROR: LoadError: TypeError: in <:, expected Type, got a value of type COSMO.CliqueGraphMerge
Stacktrace:
  [1] COSMO.SparsityPattern(L::SparseArrays.SparseMatrixCSC{Float64, Int64}, N::Int64, ordering::Vector{Int64}, merge_strategy::COSMO.OptionsFactory{COSMO.CliqueGraphMerge}, row_range::UnitRange{Int64}, cone_ind::Int64, nz_ind_map::SparseArrays.SparseVector{Int64, Int64})
    @ COSMO ~/.julia/packages/COSMO/74ztU/src/types.jl:200
  [2] _analyse_sparsity_pattern(ci::COSMO.ChordalInfo{Float64}, csp::Vector{Int64}, sets::Vector{COSMO.AbstractConvexSet}, C::COSMO.PsdConeTriangle{Float64}, k::Int64, psd_row_range::UnitRange{Int64}, sp_ind::Int64, merge_strategy::COSMO.OptionsFactory{COSMO.CliqueGraphMerge})
    @ COSMO ~/.julia/packages/COSMO/74ztU/src/chordal_decomposition/chordal_decomposition.jl:64
  [3] analyse_sparsity_pattern!(ci::COSMO.ChordalInfo{Float64}, csp::Vector{Int64}, sets::Vector{COSMO.AbstractConvexSet}, C::COSMO.PsdConeTriangle{Float64}, k::Int64, psd_row_range::UnitRange{Int64}, sp_ind::Int64, merge_strategy::COSMO.OptionsFactory{COSMO.CliqueGraphMerge})
    @ COSMO ~/.julia/packages/COSMO/74ztU/src/chordal_decomposition/chordal_decomposition.jl:55
  [4] find_sparsity_patterns!(ws::COSMO.Workspace{Float64})
    @ COSMO ~/.julia/packages/COSMO/74ztU/src/chordal_decomposition/chordal_decomposition.jl:47
  [5] chordal_decomposition!(ws::COSMO.Workspace{Float64})
    @ COSMO ~/.julia/packages/COSMO/74ztU/src/chordal_decomposition/chordal_decomposition.jl:18
  [6] macro expansion
    @ ./timing.jl:382 [inlined]
  [7] optimize!(ws::COSMO.Workspace{Float64})
    @ COSMO ~/.julia/packages/COSMO/74ztU/src/solver.jl:90
  [8] optimize!
    @ ~/.julia/packages/COSMO/74ztU/src/MOI_wrapper.jl:151 [inlined]
[...]

With the fix it's gone and things work as usual ;)

CC: @thinh-le

@migarstka migarstka merged commit 9ebf334 into oxfordcontrol:master Dec 28, 2022
@kalmarek kalmarek deleted the mk/fix_sp_pattern branch March 1, 2023 16:35
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