Conversation
|
Tests please |
|
I'll first make jump-dev/MatrixOptInterface.jl#35 and then take a miniature version of jump-dev/MatrixOptInterface.jl#35 as test here |
| v.caches = | ||
| [Tuple{_affine_function_type(T, S),S}[] for S in set_types(v.sets)] | ||
| v.are_indices_mapped = [BitSet() for _ in eachindex(v.caches)] | ||
| _reset_caches!(v) |
There was a problem hiding this comment.
These caches actually only make sense for MutableSparseMatrixCSC, it doesn't make sense for a SparseMatrixCSC nor for a MutableSparseMatrixCSR but let's not complicate this PR too much
src/Utilities/sparse_matrix.jl
Outdated
|
|
||
| function extract_function( | ||
| A::MutableSparseMatrixCSC{T}, | ||
| A::_SparseMatrixCSC{T}, |
There was a problem hiding this comment.
We can either implement it for SparseMatrixCSC here or implement it in MatrixOptInterface.
The issue of the second option is that it's type piracy and it's just a copy-paste.
One might then ask for exctract_function for Base.Matrix or Transpose{SparseMatrixCSC{Tv,Ti}} etc... But let's keep this PR simple. I think, implementing Matrix, SparseMatrixCSC and their adjoint/transpose should be good enough for 99% of the cases of this use case which is already niche ^^
|
I don't understand the codecov missing lines, it's reporting the signature of function as not covered but then its body is covered... |
|
Yeah the codecov thing is jump-dev/JuMP.jl#4088 I don't understand |
|
No objection to merge then ? |
We allow the users to create the model without using the MOI interface which might seem scary.
But this will probably only be used either by advanced users or using something like jump-dev/MatrixOptInterface.jl#35
Needed for jump-dev/MatrixOptInterface.jl#35