We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b2ce69d commit b90817aCopy full SHA for b90817a
README.md
@@ -86,6 +86,7 @@ s
86
87
```cpp
88
#include "pybind11/pybind11.h"
89
+#define FORCE_IMPORT_ARRAY
90
#include "xtensor-python/pyvectorize.hpp"
91
#include <numeric>
92
#include <cmath>
@@ -99,6 +100,7 @@ double scalar_func(double i, double j)
99
100
101
PYBIND11_MODULE(xtensor_python_test, m)
102
{
103
+ xt::import_numpy();
104
m.doc() = "Test module for xtensor python bindings";
105
106
m.def("vectorized_func", xt::pyvectorize(scalar_func), "");
0 commit comments