You
On Wed, Feb 8, 2012 at 4:32 PM, Stephanie Cooke
wrote:
> Hello,
>
> When I try to use the command hstack, I am given the error message
> "TypeError: hstack() takes exactly 1 argument (2 given)". I have a 9X1
> array (called array) that I would like to concatenate to a 9X2 matrix
> (called mat
Not exactly an answer to your question, but I can highly recommend
using Boost.python, PyUblas and Ublas for your C++ vectors and
matrices. It gives you a really good interface on the C++ side to
numpy arrays and matrices, which can be passed in both directions over
the language threshold with no c
On Mon, Jan 30, 2012 at 3:25 PM, Ted To wrote:
> Is there some straightforward way to access an array by values across a
> subset of its dimensions? For example, if I have a three dimensional
> array a=(x,y,z), can I look at the values of z given particular values
> for x and y?
a[x, y, :] shoul
>
> I suspect that you are obtaining the numpy object (1 Py_INCREF) before
> you split into multiple threads but releasing them in each thread
> (multiple Py_DECREFs). This is probably being hidden from you by the
> boost.python interface and/or the boost::detail::sp_counted_impl_p<>
> smart(ish) p
Hi,
I've built a system which allocates numpy arrays and processes them in
C++ code (this is because I'm building a native code module using
boost.python and it makes sense to use numpy data storage to then deal
with outputs in python, without having to do any copying). Everything
seems fine excep