Skip to content

Commit

Permalink
Added check for scikits.sparse
Browse files Browse the repository at this point in the history
  • Loading branch information
jellis18 committed Jan 18, 2017
1 parent ccf9a92 commit dfc37b2
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions PAL2/PALmodels.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,16 @@
from sksparse.cholmod import cholesky
SK_SPARSE = True
except ImportError:
print 'WARNING: scikit-sparse note installed, will not use sparse matrices'
SK_SPARSE=False

print 'WARNING: scikit-sparse note installed, will try scikits.sparse...'
SK_SPARSE = False

if not SK_SPARSE:
try:
from scikits.sparse.cholmod import cholesky
SK_SPARSE = True
except ImportError:
print 'WARNING: scikits.sparse note installed, will not use sparse matrices'
SK_SPARSE = False

import matplotlib.pyplot as plt

Expand Down

0 comments on commit dfc37b2

Please sign in to comment.