Discussion:
[Pyublas] by_value_ro_member
Neal Becker
2010-02-03 16:06:59 UTC
Permalink
class csm { ...

pyublas::numpy_vector<int> pdlut;
};

class_<csm> ...
.def (pyublas::by_value_ro_member ("pdlut", &csm::pdlut))

*Python*
csm.pdlut
Out[5]: <property object at 0x2203890>

? I expected to see the numpy_vector, not 'property object'. What's wrong?
Andreas Klöckner
2010-02-03 16:23:38 UTC
Permalink
Post by Neal Becker
class csm { ...
pyublas::numpy_vector<int> pdlut;
};
class_<csm> ...
.def (pyublas::by_value_ro_member ("pdlut", &csm::pdlut))
*Python*
csm.pdlut
Out[5]: <property object at 0x2203890>
? I expected to see the numpy_vector, not 'property object'. What's wrong?
Is (Python) csm an instance of (C++) csm? Or the class?

Andreas


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.tiker.net/pipermail/pyublas/attachments/20100203/78832e52/attachment.pgp>
Neal Becker
2010-02-03 16:29:47 UTC
Permalink
Post by Andreas Klöckner
Post by Neal Becker
class csm { ...
pyublas::numpy_vector<int> pdlut;
};
class_<csm> ...
.def (pyublas::by_value_ro_member ("pdlut", &csm::pdlut))
*Python*
csm.pdlut
Out[5]: <property object at 0x2203890>
? I expected to see the numpy_vector, not 'property object'. What's wrong?
Is (Python) csm an instance of (C++) csm? Or the class?
Andreas
Oops, nevermind.

Loading...