From 990892fcdec52229149d81781a7366243cf16253 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johannes=20Sch=C3=B6nberger?= Date: Thu, 21 May 2015 08:27:00 -0700 Subject: [PATCH] Replace libc.math.NAN with numpy.math.NAN for MSVC --- skimage/feature/_texture.pyx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/skimage/feature/_texture.pyx b/skimage/feature/_texture.pyx index d454a812..d716e690 100644 --- a/skimage/feature/_texture.pyx +++ b/skimage/feature/_texture.pyx @@ -4,10 +4,14 @@ #cython: wraparound=False import numpy as np cimport numpy as cnp -from libc.math cimport sin, cos, abs, NAN +from libc.math cimport sin, cos, abs from .._shared.interpolation cimport bilinear_interpolation, round +cdef extern from "numpy/npy_math.h": + double NAN "NPY_NAN" + + def _glcm_loop(cnp.uint8_t[:, ::1] image, double[:] distances, double[:] angles, Py_ssize_t levels, cnp.uint32_t[:, :, :, ::1] out):