Skip to content
This repository has been archived by the owner on Mar 5, 2021. It is now read-only.

Pybindings and Typo #1

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmake/Standalone_CMakeLists.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ IF(ADD_PYTHON)
MESSAGE(STATUS "Clone pybind11")

execute_process(
COMMAND git clone https://github.com/pybind/pybind11 ${CMAKE_CURRENT_SOURCE_DIR}/pybind11
COMMAND git clone https://github.com/pybind/pybind11 --branch v2.2.4 ${CMAKE_CURRENT_SOURCE_DIR}/pybind11
OUTPUT_VARIABLE git_output
ERROR_VARIABLE git_error
)
Expand Down
2 changes: 1 addition & 1 deletion private/PROPOSAL/Propagator.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ Geometry* Propagator::ParseGeometryConifg(const boost::property_tree::ptree& pt)
std::string origin_str = "origin";
std::string outer_radius_str = "outer_radius";
std::string inner_radius_str = "inner_radius";
std::string lenght_str = "lenght";
std::string lenght_str = "length";
std::string width_str = "width";
std::string height_str = "height";

Expand Down
2 changes: 2 additions & 0 deletions private/python/pybindings.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -849,8 +849,10 @@ PYBIND11_MODULE(pyPROPOSAL, m)
.def(py::init<const ParticleDef&, const std::vector<Sector::Definition>&, const Geometry&>(),
py::arg("particle_def"), py::arg("sector_defs"), py::arg("detector"))
.def(py::init<const ParticleDef&, const std::string&>(), py::arg("particle_def"), py::arg("config_file"))
.def(py::init<const Propagator&>(), py::arg("Propagator"))
.def("propagate", &Propagator::Propagate, py::arg("max_distance_cm") = 1e20, py::return_value_policy::reference)
.def_property_readonly("particle", &Propagator::GetParticle, "Get the internal created particle to modify its properties")
.def_property_readonly("sector", &Propagator::GetCurrentSector, "Get the current sector")
.def_property_readonly("detector", &Propagator::GetDetector, "Get the detector geometry");

// --------------------------------------------------------------------- //
Expand Down