ENH: manually set iparm & support overwrite_b
parameter
#80
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Manually set the iparm so that:
iparm(2)=103
to use an OMP version of fill-in reduce algorithm withL=10
optimizationiparm(6)=0 or 1
depends on overwrite b or notiparm(35)=1
to use 0-based indexing, hence no need to add 1 foria
andja
Support
overwrite_b
parameter:b
got an implicit copy in_check_b()
(c_contiguous
->f_contiguous
orb
is not contiguous), oroverwrite_b=True
is explicitly provided by the user, however currently the ans array still need to be allocated (I change it tonp.empty_like(b)
to avoid a 0-fill overhead) because PARDISO will try to overwritex
with 0 ifiparm(6)=1
return np.ascontiguousarray(x)
in_call_pardiso()
, in case user can benefit from keepingf_contiguous
withoverwrite_b=True
or multiplicate ccontig matrix with fcontig matrix, etc.pytest result: 1 failed, 23 passed. There is a "ValueError: scipy.sparse does not support dtype float16." I guess it is not from my changes?