Files
slsDetectorPackage/python/src/detector_in.cpp
Dhanya Thattil fff5fa73be
Some checks failed
Build on RHEL9 / build (push) Failing after 3m41s
Build on RHEL8 / build (push) Failing after 5m10s
Dev/verify shm (#1276)
* removed verify, update, fixed getUser to be a free function, generated commands, python bindings yet to do

* python bindings

* fixed tests

* minor

* minor

* format
2025-08-23 10:23:27 +02:00

30 lines
839 B
C++

// SPDX-License-Identifier: LGPL-3.0-or-other
// Copyright (C) 2021 Contributors to the SLS Detector Package
#include "py_headers.h"
#include "sls/Detector.h"
#include "sls/ToString.h"
#include "sls/network_utils.h"
#include "sls/sls_detector_defs.h"
#include "sls/TimeHelper.h"
#include <array>
#include <chrono>
namespace py = pybind11;
void init_det(py::module &m) {
using sls::defs;
using sls::Detector;
using sls::ns;
using sls::Positions;
using sls::Result;
m.def("freeSharedMemory", (void (*)(const int, const int)) &sls::freeSharedMemory, py::arg() = 0, py::arg() = -1);
m.def("getUserDetails", (std::string (*)(const int)) &sls::getUserDetails, py::arg() = 0);
py::class_<Detector> CppDetectorApi(m, "CppDetectorApi");
CppDetectorApi.def(py::init<int>());
[[FUNCTIONS]]
}