Skip to content

Commit eef3bb5

Browse files
authored
MNT drop numpy.math imports due to deprecation in recent versions of Cython. (#304)
1 parent abac5e9 commit eef3bb5

3 files changed

Lines changed: 3 additions & 6 deletions

File tree

celer/cython_utils.pyx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ cimport numpy as np
1010
from scipy.linalg.cython_blas cimport ddot, dasum, daxpy, dnrm2, dcopy, dscal
1111
from scipy.linalg.cython_blas cimport sdot, sasum, saxpy, snrm2, scopy, sscal
1212
from scipy.linalg.cython_lapack cimport sposv, dposv
13-
from libc.math cimport fabs, log, exp, sqrt
14-
from numpy.math cimport INFINITY
13+
from libc.math cimport fabs, log, exp, sqrt, INFINITY
1514
from cython cimport floating
1615

1716

celer/group_fast.pyx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,8 @@ import numpy as np
77
cimport numpy as np
88
import warnings
99

10-
from numpy.math cimport INFINITY
1110
from cython cimport floating
12-
from libc.math cimport fabs, sqrt
11+
from libc.math cimport fabs, sqrt, INFINITY
1312
from sklearn.exceptions import ConvergenceWarning
1413

1514
from .cython_utils cimport (fdot, fasum, faxpy, fnrm2, fcopy, fscal, dual,

celer/multitask_fast.pyx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ cimport numpy as np
55
import numpy as np
66
import warnings
77
from cython cimport floating
8-
from libc.math cimport fabs, sqrt
9-
from numpy.math cimport INFINITY
8+
from libc.math cimport fabs, sqrt, INFINITY
109
from sklearn.exceptions import ConvergenceWarning
1110

1211
from .cython_utils cimport fscal, fcopy, fnrm2, fdot, faxpy

0 commit comments

Comments
 (0)