Skip to content
Snippets Groups Projects
Commit 35e5018d authored by Carl Klemm's avatar Carl Klemm
Browse files

Inital commit of python bindings for eisgenerator

parent cbe9d2bb
No related branches found
No related tags found
No related merge requests found
[build-system]
requires = [
"setuptools>=42",
"pybind11>=2.9.2",
"cmake>=3.22",
"scikit-build>=0.14.1",
]
build-backend = "setuptools.build_meta"
[tool.isort]
profile = "black"
......@@ -26,7 +26,11 @@ PYBIND11_MODULE(_core, m)
.def_readwrite("omega", &DataPoint::omega)
.def_readwrite("im", &DataPoint::im);
py::class_<Range>(m, "Range")
.def(py::init<fvalue, fvalue, size_t, bool>(), py::arg("logI") = false)
.def(py::init<fvalue, fvalue, size_t, bool>(),
py::arg("startI"),
py::arg("endI"),
py::arg("countI"),
py::arg("logI") = false)
.def_readwrite("start", &Range::start)
.def_readwrite("end", &Range::end)
.def_readwrite("count", &Range::count)
......@@ -38,7 +42,6 @@ PYBIND11_MODULE(_core, m)
.value("INFO", Log::INFO)
.value("WARN", Log::WARN)
.value("ERROR", Log::ERROR);
m.def("testVector", &testVector);
py::add_ostream_redirect(m, "ostream_redirect");
m.attr("__version__") = "1.0";
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment