On Sun, Jul 26, 2015 at 11:19 AM, Sturla Molden <sturla.mol...@gmail.com> wrote:
> > we get away with np.float, because every OS/compiler that gets any > regular > > use has np.float == a c double, which is always 64 bit. > > Not if we are passing an array of np.float to a ac routine that expects > float*, e.g. in OpenGL, BLAS or LAPACK. That will for sure give crazy > results, just hang, or segfault. > well, yes, it is confusing, but at least consistent. So if you use it once correctly in your Python-C transition code, it should work the same way everywhere. As opposed to a np.int which is a python int, which is (if I have this right): 32 bits on all (most) 32 bit platforms 64 bits on 64 bit Linux and OS-X 32 bits on 64 bit Windows (also if compiled by cygwin??) And who knows on a Cray or ARM, or??? Ouch!!! Anyway -- we agree on this -- having the python types in the numpy namespace is confusing and dangerous -- even if it will take forever to deprecate them! -CHB -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception chris.bar...@noaa.gov
_______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion