From 38ef2dd63641f263557d533cc760721ed58738ea Mon Sep 17 00:00:00 2001 From: AJPfleger Date: Mon, 25 Nov 2024 10:53:49 +0100 Subject: [PATCH] new cases --- .../ActsExamples/Digitization/GeometricConfig.hpp | 9 ++++----- Examples/Python/src/Json.cpp | 2 +- .../TrackFinding/TrackParamsLookupAccumulatorTests.cpp | 10 +++++----- 3 files changed, 10 insertions(+), 11 deletions(-) diff --git a/Examples/Algorithms/Digitization/include/ActsExamples/Digitization/GeometricConfig.hpp b/Examples/Algorithms/Digitization/include/ActsExamples/Digitization/GeometricConfig.hpp index 6b4348e20f6..5df64bc4326 100644 --- a/Examples/Algorithms/Digitization/include/ActsExamples/Digitization/GeometricConfig.hpp +++ b/Examples/Algorithms/Digitization/include/ActsExamples/Digitization/GeometricConfig.hpp @@ -58,10 +58,10 @@ struct GeometricConfig { bool strip = false; /// The variances for this digitization - std::map> varianceMap = {}; + std::map> varianceMap = {}; /// Charge generation (configurable via the chargeSmearer) - Acts::ActsScalar charge(Acts::ActsScalar path, RandomEngine &rng) const { + double charge(double path, RandomEngine &rng) const { if (!chargeSmearer) { return path; } @@ -82,9 +82,8 @@ struct GeometricConfig { /// @param cmins is the cluster minimum in the different dimensions /// /// @return a vector of variances for the cluster - std::vector variances( - const std::array &csizes, - const std::array &cmins) const; + std::vector variances(const std::array &csizes, + const std::array &cmins) const; /// Drift generation (currently not implemented) /// Takes as an argument the position, and a random engine diff --git a/Examples/Python/src/Json.cpp b/Examples/Python/src/Json.cpp index 12baaa9f6d3..cbf9bfb6581 100644 --- a/Examples/Python/src/Json.cpp +++ b/Examples/Python/src/Json.cpp @@ -153,7 +153,7 @@ void addJson(Context& ctx) { .def(py::init<>()) .def(py::init, - std::pair>(), + std::pair>(), py::arg("refLayers"), py::arg("bins")); ACTS_PYTHON_STRUCT_BEGIN(c, Config); diff --git a/Tests/UnitTests/Core/TrackFinding/TrackParamsLookupAccumulatorTests.cpp b/Tests/UnitTests/Core/TrackFinding/TrackParamsLookupAccumulatorTests.cpp index 10e12747fce..358753810db 100644 --- a/Tests/UnitTests/Core/TrackFinding/TrackParamsLookupAccumulatorTests.cpp +++ b/Tests/UnitTests/Core/TrackFinding/TrackParamsLookupAccumulatorTests.cpp @@ -78,7 +78,7 @@ BOOST_AUTO_TEST_CASE(Exceptions) { // Create parameters to accumulate Acts::Vector4 pos{1, 2, 0, 4}; Acts::Vector3 dir{1, 0, 0}; - Acts::ActsScalar P = 1; + double P = 1.; auto hypothesis1 = Acts::ParticleHypothesis::electron(); auto hypothesis2 = Acts::ParticleHypothesis::muon(); @@ -143,15 +143,15 @@ BOOST_AUTO_TEST_CASE(Accumulation) { std::array fourPositions = {pos * (i + 1), pos * (i + 2), pos * (i + 3), pos * (i + 4)}; - std::array thetas = { + std::array thetas = { std::numbers::pi / (i + 1), std::numbers::pi / (i + 2), std::numbers::pi / (i + 3), std::numbers::pi / (i + 4)}; - std::array phis = { + std::array phis = { 2 * std::numbers::pi / (i + 1), 2 * std::numbers::pi / (i + 2), 2 * std::numbers::pi / (i + 3), 2 * std::numbers::pi / (i + 4)}; - Acts::ActsScalar P = 1.5 * (i + 1); + double P = 1.5 * (i + 1); // Get the point of the grid auto bin = gridBound.localBinsFromGlobalBin(i); @@ -202,7 +202,7 @@ BOOST_AUTO_TEST_CASE(Accumulation) { Acts::Vector3 avgMom = avgMoms.at(i); Acts::Vector3 avgDir = avgMom.normalized(); - Acts::ActsScalar avgP = avgMom.norm(); + double avgP = avgMom.norm(); CHECK_CLOSE_ABS(ipBound->fourPosition(gctx), avgPos, 1e-3); CHECK_CLOSE_ABS(ipBound->direction(), avgDir, 1e-3);