Permalink
Browse files

BUG: linalg: fix schur sort python 2.4 compatibility issue

  • Loading branch information...
pv authored and rgommers committed Nov 10, 2011
1 parent 18fcf38 commit d6c18adb6849dac43e02b0ea9470044bc373d375
Showing with 2 additions and 2 deletions.
  1. +2 −2 scipy/linalg/decomp_schur.py
@@ -103,9 +103,9 @@ def schur(a, output='real', lwork=None, overwrite_a=False, sort=None):
if callable(sort):
sfunction = sort
elif sort == 'lhp':
- sfunction = lambda x: (x.real < 0.0)
+ sfunction = lambda x: (numpy.real(x) < 0.0)
elif sort == 'rhp':
- sfunction = lambda x: (x.real >= 0.0)
+ sfunction = lambda x: (numpy.real(x) >= 0.0)
elif sort == 'iuc':
sfunction = lambda x: (abs(x) <= 1.0)
elif sort == 'ouc':

0 comments on commit d6c18ad

Please sign in to comment.