[Numpy-discussion] State-of-the-art to use a C/C++ library from Python

Ian Henriksen insertinterestingnamehere at gmail.com
Wed Aug 31 18:53:05 EDT 2016

On Wed, Aug 31, 2016 at 3:57 PM Jason Newton <nevion at gmail.com> wrote:

> Hey Ian - I hope I gave Cython a fair comment, but I have to add the
> disclaimer that your capability to understand/implement those
> solutions/workarounds in that project is greatly enhanced from your knowing
> the innards of Cython from being core developer on the Cython project. This
> doesn't detract from DyDN's accomplishments (if nothing it means Cython
> users should look there for how to use C++ with Cython and the workarounds
> used + shortcomings) but I would not expect not everyone would want to jump
> through those hoops to get things working without a firm understanding of
> Cython's edges, and all this potential for special/hack adaption code is
> still something to keep in mind when comparing to something more straight
> forward and easier to understand coming from a more pure C/C++ side, where
> things are a bit more dangerous and fairly more verbose but make play with
> the language and environment first-class (like Boost.Python/pybind).  Since
> this thread is a survey over state and options it's my intent just to make
> sure readers have something bare in mind for current pros/cons of the
> approaches.
> -Jason

No offense taken at all. I'm actually not a Cython developer, just a
contributor. That said, knowing the compiler internals certainly helps when
workarounds and building intermediate interfaces. My main point was just
that, in
my experience, Cython has worked well for many things beyond plain C
and that workarounds (hackery entirely aside) for any missing features are
manageable. Given that my perspective is a bit different in that regard, it
worth chiming in on the discussion. I suppose the moral of the story is
that there's
still not a clear cut "best" way of building wrappers and that your mileage
may vary
depending on what features you need.
Ian Henriksen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20160831/9365963f/attachment.html>

More information about the NumPy-Discussion mailing list