File indexing completed on 2025-01-18 09:12:03
0001
0002
0003
0004
0005
0006
0007
0008
0009 #include "Acts/Plugins/Python/Utilities.hpp"
0010 #include "ActsExamples/HepMC/HepMCProcessExtractor.hpp"
0011 #include "ActsExamples/Io/HepMC3/HepMC3Reader.hpp"
0012 #include "ActsExamples/Io/HepMC3/HepMC3Writer.hpp"
0013
0014 #include <memory>
0015
0016 #include <pybind11/pybind11.h>
0017 #include <pybind11/stl.h>
0018
0019 namespace py = pybind11;
0020 using namespace pybind11::literals;
0021
0022 using namespace Acts;
0023
0024 namespace Acts::Python {
0025 void addHepMC3(Context& ctx) {
0026 auto [m, mex] = ctx.get("main", "examples");
0027
0028 auto hepmc3 = mex.def_submodule("_hepmc3");
0029
0030 ACTS_PYTHON_DECLARE_ALGORITHM(ActsExamples::HepMCProcessExtractor, hepmc3,
0031 "HepMCProcessExtractor", inputEvents,
0032 outputSimulationProcesses, extractionProcess,
0033 absPdgMin, absPdgMax, pMin);
0034
0035 ACTS_PYTHON_DECLARE_WRITER(ActsExamples::HepMC3AsciiWriter, hepmc3,
0036 "HepMC3AsciiWriter", outputDir, outputStem,
0037 inputEvents);
0038
0039 ACTS_PYTHON_DECLARE_READER(ActsExamples::HepMC3AsciiReader, hepmc3,
0040 "HepMC3AsciiReader", inputDir, inputStem,
0041 outputEvents);
0042 }
0043 }