Commit 14095cf9 authored by Ben Huber's avatar Ben Huber
Browse files

fixed compilation of the python wrapper

parent 7fab3b64
Pipeline #715 passed with stages
in 8 minutes and 8 seconds
......@@ -15,6 +15,12 @@ functions, but once you have established, that your code works as expected you m
used by your project with one compiled with the `-D XERUS_DISABLE_RUNTIME_CHECKS` flag.
## Use c++ instead of Python
The interface between the languages python and c++ makes it necessary to perform operations for the sole purpose of compatibility
between the otherwise incompatible languages. Often this includes copies of vectors of integers (whenever dimensions are specified
or queried) and sometimes even deep copies of whole tensors (`.from_ndarray()` and `.to_ndarray()`). The only way to get rid of
this overhead is to write your appliation in c++ instead of python. Most instructions that `xerus` offers for python look very
similar in c++, so a transition might be simpler than you think. Simply check out the rest of the tutorials to compare the code
## Compiling Xerus with High Optimizations
Per default the library already compiles with high optimization settings (corresponding basically to `-O3`) as there is rarely
......@@ -487,7 +487,7 @@ BOOST_PYTHON_MODULE(xerus) {
"value : int"
.def("remove_slate", &Tensor::remove_slate,
((arg("mode"), arg("pos")),
(arg("mode"), arg("pos")),
"Removes a single slate from the Tensor, reducing dimension[mode] by one."
"mode : int\n"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment