Skip to content

Commit

Permalink
change iparm 12
Browse files Browse the repository at this point in the history
  • Loading branch information
jd-lara committed Sep 28, 2023
1 parent 643f7d3 commit 62370e4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/lodf_calculations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,14 @@ function _pardiso_single_LODF!(
linecount = size(lodf_t, 1)
ps = Pardiso.MKLPardisoSolver()
Pardiso.pardisoinit(ps)
Pardiso.set_iparm!(ps, 1, 1)
for (ix, v) in enumerate(defaults[2:end])
Pardiso.set_iparm!(ps, ix + 1, v)
end
Pardiso.set_iparm!(ps, 2, 2)
Pardiso.set_iparm!(ps, 59, 2)
Pardiso.set_iparm!(ps, 6, 1)
Pardiso.set_iparm!(ps, 12, 1)
#Pardiso.set_msglvl!(ps, Pardiso.MESSAGE_LEVEL_ON)
Pardiso.pardiso(
ps,
Expand Down
2 changes: 2 additions & 0 deletions src/ptdf_calculations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,7 @@ function _calculate_PTDF_matrix_MKLPardiso(
ABA = calculate_ABA_matrix(A, BA, ref_bus_positions)
# Here add the subnetwork detection
ps = Pardiso.MKLPardisoSolver()
Pardiso.pardisoinit(ps)
# Pardiso.set_msglvl!(ps, Pardiso.MESSAGE_LEVEL_ON)
defaults = Pardiso.get_iparms(ps)
Pardiso.set_iparm!(ps, 1, 1)
Expand All @@ -279,6 +280,7 @@ function _calculate_PTDF_matrix_MKLPardiso(
Pardiso.set_iparm!(ps, 2, 2)
Pardiso.set_iparm!(ps, 59, 2)
Pardiso.set_iparm!(ps, 6, 1)
Pardiso.set_iparm!(ps, 12, 1)

# inizialize matrices for evaluation
valid_ix = setdiff(1:buscount, ref_bus_positions)
Expand Down

0 comments on commit 62370e4

Please sign in to comment.