mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-30 14:35:15 +02:00
Seems to work on windows now
not everything works yet, but I've identified the main issues. Still TODO: handle missing OMP libraries gracefully
This commit is contained in:
parent
de0a5d0e70
commit
6945ad7aa1
2 changed files with 14 additions and 10 deletions
|
|
@ -325,6 +325,7 @@ def symmetrify(A, upper=False):
|
|||
"""
|
||||
N, M = A.shape
|
||||
assert N == M
|
||||
|
||||
c_contig_code = """
|
||||
int iN;
|
||||
for (int i=1; i<N; i++){
|
||||
|
|
@ -343,6 +344,8 @@ def symmetrify(A, upper=False):
|
|||
}
|
||||
}
|
||||
"""
|
||||
|
||||
N = int(N) # for safe type casting
|
||||
if A.flags['C_CONTIGUOUS'] and upper:
|
||||
weave.inline(f_contig_code, ['A', 'N'], extra_compile_args=['-O3'])
|
||||
elif A.flags['C_CONTIGUOUS'] and not upper:
|
||||
|
|
@ -403,4 +406,3 @@ def backsub_both_sides(L, X, transpose='left'):
|
|||
else:
|
||||
tmp, _ = lapack.dtrtrs(L, np.asfortranarray(X), lower=1, trans=0)
|
||||
return lapack.dtrtrs(L, np.asfortranarray(tmp.T), lower=1, trans=0)[0].T
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue