Michael Droettboom wrote:
> It's funny you should mention this.
> 
> One of the things I realized after SciPy this year is that there is a 
> lot of interfacing of Numpy with C++ (as opposed to C) that could really 
> benefit from a standard C++ wrapper around Numpy.

Absolutely. Though now that you mention it, isn't there one in 
boost::python? or at least one that worked with Numeric.

> projects all had home-grown, semi-complete solutions.
> A standard wrapper would be good for all of the reasons you mention 
> (basically resource management), but also to have a cleaner syntax for 
> accessing the elements that would abstract away striding, ordering etc.  

I think I'm thinking of something slightly different. What I'd like is 
set of array classes that can interface well with numpy, and also be 
quite usable all by themselves in C++ code that has nothing to do with 
python.

I don't really envision a C++ ndarray -- I generally think of C++ as 
static enough that I'm happy to define that I need, for example, a NX2 
array of doubles. I don't see using a generic array like ndarray that 
could hold any type, shape, etc. But maybe others do -- it would be 
pretty cool.

I guess to some extent the question is whether you are writing 
extensions for python, or a C++ that you want to use from C++, and also 
wrap for python.

But maybe both need can be met by the same C++ classes (templates?)

> It may actually be possible to build it around boost::multiarray

Do you know off hand if multiarray can be constructed from an existing 
pointer to a data block?

> Can't imagine I'll find time for it anytime soon,

too bad, but if you do -- I'd love to hear about it!

-Chris


-- 
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

[EMAIL PROTECTED]

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to