improved docs and added PixelMap

This commit is contained in:
Erik Fröjdh
2024-10-31 08:56:12 +01:00
parent 92d9c28c73
commit 19c6a4091f
11 changed files with 220 additions and 111 deletions

View File

@ -1,16 +1,16 @@
//Files with bindings to the different classes
#include "file.hpp"
#include "var_cluster.hpp"
#include "pixel_map.hpp"
//Pybind stuff
#include <pybind11/pybind11.h>
#include <pybind11/stl.h>
namespace py = pybind11;
PYBIND11_MODULE(_aare, m) {
define_file_io_bindings(m);
define_var_cluster_finder_bindings(m);
define_pixel_map_bindings(m);
}

21
python/src/pixel_map.hpp Normal file
View File

@ -0,0 +1,21 @@
#include "aare/PixelMap.hpp"
#include "np_helper.hpp"
#include <cstdint>
#include <pybind11/numpy.h>
#include <pybind11/pybind11.h>
#include <pybind11/stl.h>
namespace py = pybind11;
using namespace::aare;
void define_pixel_map_bindings(py::module &m) {
m.def("GenerateMoench03PixelMap", []() {
auto ptr = new NDArray<size_t,2>(GenerateMoench03PixelMap());
return return_image_data(ptr);
});
}