Re: [Numpy-discussion] polynomial with negative exponents

2011-12-12 Thread Gregor Thalhammer
Am 12.12.2011 um 15:04 schrieb LASAGNA DAVIDE: Hi, I have written a class for polynomials with negative exponents like: p(x) = a0 + a1*x**-1 + ... + an*x**-n The code is this one: class NegativeExpPolynomial( object ): def __init__ ( self, coeffs ): self.coeffs =

Re: [Numpy-discussion] Owndata flag

2011-12-15 Thread Gregor Thalhammer
Am 15.12.2011 um 17:17 schrieb Fabrice Silva: How can one arbitrarily assumes that an ndarray owns its data ? More explicitly, I have some temporary home-made C structure that holds a pointer to an array. I prepare (using Cython) an numpy.ndarray using the PyArray_NewFromDescr function. I

Re: [Numpy-discussion] Owndata flag

2011-12-16 Thread Gregor Thalhammer
Am 16.12.2011 um 11:53 schrieb Fabrice Silva: Le jeudi 15 décembre 2011 à 18:09 +0100, Gregor Thalhammer a écrit : There is an excellent blog entry from Travis Oliphant, that describes how to create a ndarray from existing data without copy: http://blog.enthought.com/?p=62 The created

Re: [Numpy-discussion] mkl usage

2012-02-24 Thread Gregor Thalhammer
Am 24.2.2012 um 13:54 schrieb Neal Becker: Francesc Alted wrote: On Feb 23, 2012, at 2:19 PM, Neal Becker wrote: Pauli Virtanen wrote: 23.02.2012 20:44, Francesc Alted kirjoitti: On Feb 23, 2012, at 1:33 PM, Neal Becker wrote: Is mkl only used for linear algebra? Will it speed up

Re: [Numpy-discussion] numpythonically getting elements with the minimum sum

2013-01-29 Thread Gregor Thalhammer
Am 28.1.2013 um 23:15 schrieb Lluís: Hi, I have a somewhat convoluted N-dimensional array that contains information of a set of experiments. The last dimension has as many entries as iterations in the experiment (an iterative application), and the penultimate dimension has as many

Re: [Numpy-discussion] Custom floating point representation to IEEE 754 double

2014-02-26 Thread Gregor Thalhammer
Am 25.02.2014 um 12:08 schrieb Daniele Nicolodi dani...@grinta.net: Hello, I'm dealing with an instrument that transfers numerical values through an RS232 port in a custom (?) floating point representation (56 bits, 4 bits exponent and 52 bits significand). Of course I need to convert

Re: [Numpy-discussion] numpy gsoc topic idea: configurable algorithm precision and vector math library integration

2014-03-06 Thread Gregor Thalhammer
Am 03.03.2014 um 20:20 schrieb Julian Taylor jtaylor.deb...@googlemail.com: hi, as the numpy gsoc topic page is a little short on options I was thinking about adding two topics for interested students. But as I have no experience with gsoc or mentoring and the ideas are not very fleshed

Re: [Numpy-discussion] GSoC project: draft of proposal

2014-03-14 Thread Gregor Thalhammer
Am 13.03.2014 um 18:35 schrieb Leo Mao lmao20...@gmail.com: Hi, Thanks a lot for your advice, Chuck. Following your advice, I have modified my draft of proposal. (attachment) I think it still needs more comments so that I can make it better. And I found that maybe I can also make some

Re: [Numpy-discussion] GSoC project: draft of proposal

2014-03-14 Thread Gregor Thalhammer
Am 14.03.2014 um 11:00 schrieb Eric Moore e...@redtetrahedron.org: On Friday, March 14, 2014, Gregor Thalhammer gregor.thalham...@gmail.com wrote: Am 13.03.2014 um 18:35 schrieb Leo Mao lmao20...@gmail.com: Hi, Thanks a lot for your advice, Chuck. Following your advice, I

Re: [Numpy-discussion] Inverted indices

2014-08-07 Thread Gregor Thalhammer
Am 07.08.2014 um 13:16 schrieb Nicolas P. Rougier nicolas.roug...@inria.fr: Hi, I've a small problem for which I cannot find a solution and I'm quite sure there is an obvious one: I've an array Z (any dtype) with some data. I've a (sorted) array I (of integer, same size as Z) that

Re: [Numpy-discussion] Inverted indices

2014-08-07 Thread Gregor Thalhammer
Am 07.08.2014 um 13:59 schrieb Gregor Thalhammer gregor.thalham...@gmail.com: Am 07.08.2014 um 13:16 schrieb Nicolas P. Rougier nicolas.roug...@inria.fr: Hi, I've a small problem for which I cannot find a solution and I'm quite sure there is an obvious one: I've an array Z (any

Re: [Numpy-discussion] Help in speeding up accumulation in a matrix

2011-01-30 Thread Gregor Thalhammer
Am 29.1.2011 um 22:01 schrieb Nicolas SCHEFFER: Hi all, First email to the list for me, I just want to say how grateful I am to have python+numpy+ipython etc... for my day to day needs. Great combination of software. Anyway, I've been having this bottleneck in one my algorithms that has

Re: [Numpy-discussion] glumpy, fast opengl visualization

2010-01-27 Thread Gregor Thalhammer
2010/1/25 Nicolas Rougier nicolas.roug...@loria.fr: Hello, This is an update about glumpy, a fast-OpenGL based numpy visualization. I modified the code such that the only dependencies are PyOpenGL and IPython (for interactive sessions). You will also need matplotlib and scipy for some

[Numpy-discussion] failure with numpy.inner

2008-07-05 Thread Gregor Thalhammer
the reason for this behaviour (and fix it). Gregor Thalhammer ___ Numpy-discussion mailing list Numpy-discussion@scipy.org http://projects.scipy.org/mailman/listinfo/numpy-discussion

Re: [Numpy-discussion] Fast and efficient way to convert an array into binary

2008-11-18 Thread Gregor Thalhammer
frank wang schrieb: Hi, I have a large array and I want to convert it into a binary array. For exampe, y=array([1,2,3]), after the convertion I want the result array([0,0,0,1,0,0,1,0,0,0,1,1]). Each digit is converted into 4 bits in this example. In my real problem I want to convert

Re: [Numpy-discussion] contiguous regions

2008-11-20 Thread Gregor Thalhammer
John Hunter schrieb: I frequently want to break a 1D array into regions above and below some threshold, identifying all such subslices where the contiguous elements are above the threshold. I have two related implementations below to illustrate what I am after. The first crossings is rather

Re: [Numpy-discussion] ANN: Numexpr 1.1, an efficient array evaluator

2009-01-16 Thread Gregor Thalhammer
Francesc Alted schrieb: Numexpr is a fast numerical expression evaluator for NumPy. With it, expressions that operate on arrays (like 3*a+4*b) are accelerated and use less memory than doing the same calculation in Python. The expected speed-ups for Numexpr respect to NumPy are between 0.95x

Re: [Numpy-discussion] ANN: Numexpr 1.1, an efficient array evaluator

2009-01-16 Thread Gregor Thalhammer
Francesc Alted schrieb: A Friday 16 January 2009, Gregor Thalhammer escrigué: I also gave a try to the vector math library (VML), contained in Intel's Math Kernel Library. This offers a fast implementation of mathematical functions, operating on array. First I implemented a C extension

Re: [Numpy-discussion] Fast threading solution thoughts

2009-02-12 Thread Gregor Thalhammer
Brian Granger schrieb: I am curious: would you know what would be different in numpy's case compared to matlab array model concerning locks ? Matlab, up to recently, only spreads BLAS/LAPACK on multi-cores, but since matlab 7.3 (or 7.4), it also uses multicore for mathematical functions (cos,

[Numpy-discussion] numexpr and numpy windows binaries built with MKL

2009-02-12 Thread Gregor Thalhammer
Hi all, as Francesc announced, the latest release of Numexpr 1.2 can be built with Intels Math Kernel Library, which gives a BIGbig increase in performance. Now the questions: Could somebody provide binaries for Windows of Numexpr, linked with Intels MKL? I know, there is the license problem.

Re: [Numpy-discussion] Integer cast problems

2009-02-12 Thread Gregor Thalhammer
Ralph Kube schrieb: Hi there, I have a little problem here with array indexing, hope you see the problem. I use the following loop to calculate some integrals ... 0.145 * 0.005 = 28.996 N.int32(0.145 * 0.005) = 28 conversion to int truncates, it doesn't round. Try N.int32(0.145

Re: [Numpy-discussion] Build with MKL on linux

2009-02-20 Thread Gregor Thalhammer
Neal Becker schrieb: Trying to build numpy-1.2.1 with intel mkl 10.1.1.019 on linux F10 x86_64. echo $LD_LIBRARY_PATH /opt/intel/mkl/10.1.1.019/lib/em64t strace -e trace=file python -c 'import numpy; numpy.test()' 2stuff Running unit tests for numpy NumPy version 1.2.1 NumPy is installed

Re: [Numpy-discussion] memoization with ndarray arguments

2009-03-22 Thread Gregor Thalhammer
Paul Northug schrieb: I would like to 'memoize' the objective, derivative and hessian functions, each taking a 1d double ndarray argument X, that are passed as arguments to scipy.optimize.fmin_ncg. Each of these 3 functions has calculations in common that are expensive to compute and are a

Re: [Numpy-discussion] numpy ufuncs and COREPY - any info?

2009-05-22 Thread Gregor Thalhammer
dmitrey schrieb: hi all, has anyone already tried to compare using an ordinary numpy ufunc vs that one from corepy, first of all I mean the project http://socghop.appspot.com/student_project/show/google/gsoc2009/python/t124024628235 It would be interesting to know what is speedup for (eg)

Re: [Numpy-discussion] where are the benefits of ldexp and/or array times 2?

2009-05-22 Thread Gregor Thalhammer
dmitrey schrieb: Hi all, I expected to have some speedup via using ldexp or multiplying an array by a power of 2 (doesn't it have to perform a simple shift of mantissa?), but I don't see the one. # Let me also note - # 1) using b = 2 * ones(N) or b = zeros(N) doesn't yield any speedup vs b

Re: [Numpy-discussion] Objected-oriented SIMD API for Numpy

2009-10-22 Thread Gregor Thalhammer
2009/10/21 Neal Becker ndbeck...@gmail.com ... I once wrote a module that replaces the built in transcendental functions of numpy by optimized versions from Intels vector math library. If someone is interested, I can publish it. In my experience it was of little use since real world

Re: [Numpy-discussion] Introductory mail and GSoc Project Vector math library integration

2015-03-11 Thread Gregor Thalhammer
Am 08.03.2015 um 21:47 schrieb Dp Docs sdpa...@gmail.com: Hi all, I am a CS 3rd Undergrad. Student from an Indian Institute (III T). I believe I am good in Programming languages like C/C++, Python as I have already done Some Projects using these language as a part of my academics. I

Re: [Numpy-discussion] Introductory mail and GSoc Project Vector math library integration

2015-03-12 Thread Gregor Thalhammer
Am 11.03.2015 um 23:18 schrieb Dp Docs sdpa...@gmail.com: On Wed, Mar 11, 2015 at 10:34 PM, Gregor Thalhammer gregor.thalham...@gmail.com mailto:gregor.thalham...@gmail.com wrote: On the scipy mailing list I also answered to Amine, who is also interested in this proposal

Re: [Numpy-discussion] Introductory mail and GSoc Project Vector math library integration

2015-03-24 Thread Gregor Thalhammer
Am 12.03.2015 um 13:48 schrieb Julian Taylor jtaylor.deb...@googlemail.com: On 03/12/2015 10:15 AM, Gregor Thalhammer wrote: Another note, numpy makes it easy to provide new ufuncs, see http://docs.scipy.org/doc/numpy-dev/user/c-info.ufunc-tutorial.html from a C function that operates

Re: [Numpy-discussion] Changing FFT cache to a bounded LRU cache

2016-06-01 Thread Gregor Thalhammer
> Am 31.05.2016 um 23:36 schrieb Sturla Molden : > > Joseph Martinot-Lagarde wrote: > >> The problem with FFTW is that its license is more restrictive (GPL), and >> because of this may not be suitable everywhere numpy.fft is. > > A lot of us use

Re: [Numpy-discussion] Linking other libm-Implementation

2016-02-09 Thread Gregor Thalhammer
c: https://sourceware.org/glibc/wiki/libmvec > <https://sourceware.org/glibc/wiki/libmvec>). > > 2016-02-08 23:32 GMT+01:00 Gregor Thalhammer <gregor.thalham...@gmail.com > <mailto:gregor.thalham...@gmail.com>>: > Years ago I made the vectorized math functions from Intels Vec

Re: [Numpy-discussion] Linking other libm-Implementation

2016-02-08 Thread Gregor Thalhammer
> Am 08.02.2016 um 18:36 schrieb Nathaniel Smith : > > On Feb 8, 2016 3:04 AM, "Nils Becker" > wrote: > > > [...] > > Very superficial benchmarks (see below) seem devastating for gnu libm. It > > seems that openlibm

Re: [Numpy-discussion] Numexpr-3.0 proposal

2016-02-15 Thread Gregor Thalhammer
> Am 14.02.2016 um 23:19 schrieb Robert McLeod : > > Hello everyone, > > I've done some work on making a new version of Numexpr that would fix some of > the limitations of the original virtual machine with regards to data types > and operation/function count. Basically I