[Numpy-discussion] access ndarray in C++

Hoyt Koepke hoytak@gmail....
Sat Apr 26 15:52:38 CDT 2008

Let me say also that I tried using boost.python a while back to
interface numpy with c++, and, while I got some things working, I
found the distribution and packaging end of things an order of
magnitude more complicated than what I found with weave.  Since weave
is built into scipy, as well as blitz itself (now recently under the
BSD license), it fits really well with numpy's distutils.  The only
dependencies on the user end are numpy and scipy, which they would
need anyway from the python end of the code.

Also, I find the syntax of blitz++ to be really simple and numpy-like.  E.g.

Array<double, 2> A;
for(int i = 0; i < 20; ++i)      A(i, Range::all() ) = i;
Array<double, 1> B = A(Range(2,18), 0);
B *= 2;
A(2, Range(5,10) ) += 2;
Array<double, 1> C = B*A(2, Range(1,17) );

and so on...  (I just typed this in here, prob some typos).

Anyway, after bouncing around for a bit I think I've found this to be
the solution that most closely fits my needs.

On Sat, Apr 26, 2008 at 3:54 AM, Gael Varoquaux
<gael.varoquaux@normalesup.org> wrote:
> On Wed, Apr 23, 2008 at 09:47:46PM -0400, Andreas Klöckner wrote:
>  > > Any numpy-specific stuff for sip?
>  > Not as far as I'm aware. In fact, I don't know of any uses of sip outside of
>  > Qt/KDE-related things.
>  Airbus uses it for heavy numerical work. They claim they have benchmarked
>  all the tools and SIP was the fastest.
>  If you want more information on that, you should contact the sip
>  developer, Phil Thompson, he does some contracting job for Airbus.
>  Cheers,
>  Gaël
> _______________________________________________
>  Numpy-discussion mailing list
>  Numpy-discussion@scipy.org
>  http://projects.scipy.org/mailman/listinfo/numpy-discussion

Hoyt Koepke
UBC Department of Computer Science

More information about the Numpy-discussion mailing list