Auto generating Python bindings (#70)

Auto generating python bindings
This commit is contained in:
Erik Fröjdh
2020-01-07 15:47:38 +01:00
committed by GitHub
parent 086cbacd84
commit ed2a69744b
12 changed files with 481 additions and 268 deletions

View File

@ -0,0 +1,21 @@
#include <pybind11/chrono.h>
#include <pybind11/operators.h>
#include <pybind11/pybind11.h>
#include <pybind11/stl.h>
#include "Detector.h"
#include "ToString.h"
#include "network_utils.h"
#include "sls_detector_defs.h"
#include "typecaster.h"
namespace py = pybind11;
void init_det(py::module &m) {
using sls::Detector;
using sls::Positions;
py::class_<Detector> CppDetectorApi(m, "CppDetectorApi");
CppDetectorApi
.def(py::init<int>())
[[FUNCTIONS]]
}