mirror of
https://github.com/wassname/scikit-image.git
synced 2026-10-30 13:40:44 +08:00
Fix: round function is not provided by libc.math on all platforms
This commit is contained in:
1 parent
e346d6b11b
commit
0cf582865e
1 file changed
+5
-1
@@ -2,7 +2,11 @@
|
||||
#cython: boundscheck=False
|
||||
#cython: nonecheck=False
|
||||
#cython: wraparound=False
|
||||
from libc.math cimport ceil, floor, round
|
||||
from libc.math cimport ceil, floor
|
||||
|
||||
|
||||
cdef inline int round(double r):
|
||||
return <int>((r + 0.5) if (r > 0.0) else (r - 0.5))
|
||||
|
||||
|
||||
cdef inline double nearest_neighbour_interpolation(double* image, int rows,
|
||||
|
||||
Reference in new issue
Block a user