This section attempts to outline some of the basic principles of the NekPy wrapper, which
relies entirely on the excellent Boost.Python
library. An extensive documentation is therefore
beyond the scope of this document, but we highlight aspects that are important for the NekPy
wrappers.
In general, note that when things go wrong with Boost.Python
, it’ll be indicated either by an
extensive compiler error, or a runtime error in the Python interpreter when you try to use
your wrapper. Judicious use of Google is therefore recommended to track down these
issues!
You may also find the following resources useful:
Boost.Python
tutorial [22],
Boost.Python
entry on the Python wiki [2],
To demonstrate how to wrap classes, we’ll refer to a number of existing parts of the code below.