From 78719bae00615524d0e76465ca81ce23fd557ede Mon Sep 17 00:00:00 2001 From: Stephen Nicholas Swatman Date: Fri, 20 Sep 2024 11:13:54 +0200 Subject: [PATCH] build: Update traccc to v0.16.0 This commit updates traccc to version 0.16.0 and, with it, detray to v0.75.2. --- CMakeLists.txt | 4 +- .../ActsExamples/Traccc/DetrayPropagator.hpp | 2 +- Examples/Python/src/Traccc.cpp | 5 ++- Plugins/Detray/CMakeLists.txt | 3 +- cmake/ActsExternSources.cmake | 4 +- thirdparty/detray/CMakeLists.txt | 17 +++++++- thirdparty/traccc/CMakeLists.txt | 7 +--- thirdparty/traccc/warnings.diff | 40 ------------------- 8 files changed, 27 insertions(+), 55 deletions(-) delete mode 100644 thirdparty/traccc/warnings.diff diff --git a/CMakeLists.txt b/CMakeLists.txt index 2444a405ab6..611395e94f7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -237,8 +237,8 @@ set(_acts_root_version 6.20) set(_acts_tbb_version 2020.1) set(_acts_pythia8_version 8.309) set(_acts_pybind11_version 2.13.1) -set(_acts_detray_version 0.72.1) -set(_acts_traccc_version 0.15.0) +set(_acts_detray_version 0.75.2) +set(_acts_traccc_version 0.16.0) set(_acts_covfie_version 0.10.0) set(_acts_vecmem_version 1.4.0) set(_acts_algebraplugins_version 0.22.0) diff --git a/Examples/Algorithms/Traccc/include/ActsExamples/Traccc/DetrayPropagator.hpp b/Examples/Algorithms/Traccc/include/ActsExamples/Traccc/DetrayPropagator.hpp index 8c42ecbeab0..8e7e415fa4e 100644 --- a/Examples/Algorithms/Traccc/include/ActsExamples/Traccc/DetrayPropagator.hpp +++ b/Examples/Algorithms/Traccc/include/ActsExamples/Traccc/DetrayPropagator.hpp @@ -17,7 +17,7 @@ #include "ActsExamples/Traccc/DetrayStore.hpp" #include -#include +#include namespace ActsExamples { diff --git a/Examples/Python/src/Traccc.cpp b/Examples/Python/src/Traccc.cpp index d620a5584f7..e5a5f22be7e 100644 --- a/Examples/Python/src/Traccc.cpp +++ b/Examples/Python/src/Traccc.cpp @@ -25,7 +25,6 @@ #include #include #include -#include #include #include #include @@ -72,7 +71,9 @@ void addTraccc(Context& ctx) { // Navigation with inspection using DetrayNavigator = - detray::navigator; + detray::navigator; // Line stepper using DetrayLineStepper = detray::line_stepper; diff --git a/Plugins/Detray/CMakeLists.txt b/Plugins/Detray/CMakeLists.txt index 79d56b37cf0..470315de788 100644 --- a/Plugins/Detray/CMakeLists.txt +++ b/Plugins/Detray/CMakeLists.txt @@ -24,7 +24,8 @@ target_link_libraries( detray::core detray::core_array detray::io - detray::utils + detray::detectors + detray::test_utils vecmem::core ) diff --git a/cmake/ActsExternSources.cmake b/cmake/ActsExternSources.cmake index c5b332e7316..3352fec959a 100644 --- a/cmake/ActsExternSources.cmake +++ b/cmake/ActsExternSources.cmake @@ -27,14 +27,14 @@ set(ACTS_COVFIE_SOURCE mark_as_advanced(ACTS_COVFIE_SOURCE) set(ACTS_DETRAY_SOURCE - "URL;https://github.com/acts-project/detray/archive/refs/tags/v${_acts_detray_version}.tar.gz;URL_HASH;SHA256=6cc8d34bc0d801338e9ab142c4a9884d19d9c02555dbb56972fab86b98d0f75b" + "URL;https://github.com/acts-project/detray/archive/refs/tags/v${_acts_detray_version}.tar.gz;URL_HASH;SHA256=249066c138eac4114032e8d558f3a05885140a809332a347c7667978dbff54ee" CACHE STRING "Source to take DETRAY from" ) mark_as_advanced(ACTS_DETRAY_SOURCE) set(ACTS_TRACCC_SOURCE - "URL;https://github.com/acts-project/traccc/archive/refs/tags/v${_acts_traccc_version}.tar.gz;URL_HASH;SHA256=1a9a1d0d2f6c4a7773eae3119b1e044fb52031ca49dfc88e6dc4ab8a11df167e" + "URL;https://github.com/acts-project/traccc/archive/refs/tags/v${_acts_traccc_version}.tar.gz;URL_HASH;SHA256=86e0ebe7364d3a2106301d50a89feef583470da53c9dae6d1430dcc6eda7dba9" CACHE STRING "Source to take TRACCC from" ) diff --git a/thirdparty/detray/CMakeLists.txt b/thirdparty/detray/CMakeLists.txt index c24b260b0ff..5b2bcee1d59 100644 --- a/thirdparty/detray/CMakeLists.txt +++ b/thirdparty/detray/CMakeLists.txt @@ -30,16 +30,31 @@ set(DETRAY_CUSTOM_SCALARTYPE "Scalar type to use in the Detray code" ) -set(DETRAY_BUILD_TESTING +set(DETRAY_BUILD_TEST_UTILS + ON + CACHE BOOL + "Turn on the build of the Detray test utilities" +) +set(DETRAY_BUILD_UNITTESTS OFF CACHE BOOL "Turn off the build of the Detray unit tests" ) +set(DETRAY_BUILD_INTEGRATIONTESTS + OFF + CACHE BOOL + "Turn off the build of the Detray integration tests" +) set(DETRAY_BUILD_TUTORIALS OFF CACHE BOOL "Turn off the build of the Detray tutorials" ) +set(DETRAY_BUILD_BENCHMARKS + OFF + CACHE BOOL + "Turn off the build of the Detray benchmarks" +) set(DETRAY_EIGEN_PLUGIN ON CACHE BOOL diff --git a/thirdparty/traccc/CMakeLists.txt b/thirdparty/traccc/CMakeLists.txt index 6271b5ef0c3..705593f34d8 100644 --- a/thirdparty/traccc/CMakeLists.txt +++ b/thirdparty/traccc/CMakeLists.txt @@ -15,12 +15,7 @@ message(STATUS "Building traccc as part of the Acts project") set(TRACCC_VERSION "${_acts_traccc_version}") # Declare where to get traccc from. -FetchContent_Declare( - traccc - ${ACTS_TRACCC_SOURCE} - # Needed until https://github.com/acts-project/traccc/pull/682 and https://github.com/acts-project/traccc/pull/683 are deployed - PATCH_COMMAND patch -p1 -i ${CMAKE_CURRENT_SOURCE_DIR}/warnings.diff -) +FetchContent_Declare(traccc ${ACTS_TRACCC_SOURCE}) if(ACTS_CUSTOM_SCALARTYPE) set(ACTS_TRACCC_SCALARTYPE ${ACTS_CUSTOM_SCALARTYPE}) diff --git a/thirdparty/traccc/warnings.diff b/thirdparty/traccc/warnings.diff deleted file mode 100644 index 78fa1f37118..00000000000 --- a/thirdparty/traccc/warnings.diff +++ /dev/null @@ -1,40 +0,0 @@ -diff --git a/core/include/traccc/seeding/spacepoint_binning_helper.hpp b/core/include/traccc/seeding/spacepoint_binning_helper.hpp -index 56a068d4..5a4f2ff2 100644 ---- a/core/include/traccc/seeding/spacepoint_binning_helper.hpp -+++ b/core/include/traccc/seeding/spacepoint_binning_helper.hpp -@@ -99,7 +99,8 @@ inline std::pair, detray::axis2::regular<>> get_axes( - - scalar zBinSize = grid_config.cotThetaMax * grid_config.deltaRMax; - detray::dindex zBins = std::max( -- 1, (int)std::floor((grid_config.zMax - grid_config.zMin) / zBinSize)); -+ 1, static_cast( -+ std::floor((grid_config.zMax - grid_config.zMin) / zBinSize))); - - detray::axis2::regular m_z_axis{zBins, grid_config.zMin, grid_config.zMax, - mr}; -diff --git a/io/src/csv/read_cells.cpp b/io/src/csv/read_cells.cpp -index a80d8f92..1451202f 100644 ---- a/io/src/csv/read_cells.cpp -+++ b/io/src/csv/read_cells.cpp -@@ -58,7 +58,7 @@ traccc::cell_module get_module(const std::uint64_t geometry_id, - } - - // Set the value on the module description. -- result.placement = (*geom)[result.surface_link.value()]; -+ result.placement = geom->at(result.surface_link.value()); - } - - // Find/set the digitization configuration of the detector module. -diff --git a/io/src/csv/read_spacepoints.cpp b/io/src/csv/read_spacepoints.cpp -index b2a38aba..41922683 100644 ---- a/io/src/csv/read_spacepoints.cpp -+++ b/io/src/csv/read_spacepoints.cpp -@@ -59,7 +59,7 @@ void read_spacepoints(spacepoint_reader_output& out, std::string_view filename, - m[iohit.geometry_id] = link; - cell_module mod; - mod.surface_link = detray::geometry::barcode{iohit.geometry_id}; -- mod.placement = geom[iohit.geometry_id]; -+ mod.placement = geom.at(iohit.geometry_id); - result_modules.push_back(mod); - } -