Skip to content

Commit

Permalink
Merge pull request #794 from 36000/bd_fixes
Browse files Browse the repository at this point in the history
[FIX] Some fixes for nightly tests
  • Loading branch information
arokem committed Feb 10, 2022
2 parents 2002e20 + 55ac541 commit 5b3e32f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion AFQ/_fixes.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import numpy as np
from scipy.sparse.linalg import ArpackNoConvergence

from scipy.special import lpmv, gammaln

Expand Down Expand Up @@ -244,7 +245,9 @@ def solve_qp(P, Q, G, H):
try:
prob.solve()
opt = np.array(x.value).reshape((Q.shape[0],))
except (cvx.error.SolverError, cvx.error.DCPError):
except (
cvx.error.SolverError, cvx.error.DCPError,
ArpackNoConvergence):
opt = np.empty((Q.shape[0],))
opt[:] = np.NaN

Expand Down
2 changes: 1 addition & 1 deletion AFQ/tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ def test_AFQ_slr():

seg_sft = aus.SegmentedSFT.fromfile(
myafq.clean_bundles["01"])
npt.assert_(len(seg_sft.get_bundle.streamlines('CST_L')) > 0)
npt.assert_(len(seg_sft.get_bundle('CST_L').streamlines) > 0)


@pytest.mark.nightly_reco
Expand Down

0 comments on commit 5b3e32f

Please sign in to comment.