Tags: alisw/root
Tags
[runtime-cxxmodules] Add overlay entry for MacOSX15.2
[runtime-cxmodules] Use separate modulemap for macOS15.2
Fix build issue on macOS 15.4 / XCode 16.3 `less` is defined in functional according to the C++ standard.
Revert "Remove the deprecated Pythia 6 interface" This reverts commit 4e30f26.
Revert "Remove the deprecated Pythia 6 interface" This reverts commit 4e30f26.
[geom] New BVH/VoxelGrid-based implementation of TGeoParallelWorld ro… …utines This commit provides a rewrite of key functions of TGeoParallelWorld, achieving: (a) faster initialization (b) faster execution of the Safety function (from ~O(N) to ~O(1)) (c) similar execution of FindNode/FindBoundary functions (~log(N)) (d) less memory consumption (better memory scalability) The development for this commit was motivated from a use case in ALICE, in which the parallel world "scene" can be very large (~100K volumes). In this case, TGeoVoxelFinder takes very long to construct and consumes a very large amount of memory (GBs). In addition, the evaluation of the Safety function dominates the Geant simulation time. The improvements in this commit are mainly achieved through: * The use of a boundary volume hierarchy (BVH) as the base acceleration entity, replacing TGeoVoxelFinder. BVH are the standard in industry/computer-graphics, for what concerns ray-object intersection tasks. The BVH is constructed from axis-aligned bounding boxes and employed in the FindBoundary/FindNode implementations * The use of a 3D voxel grid (TGeoVoxelGrid) structure, able to store properties "local" or in the vicinity of a cartesian coordinate P. This structure allows to reduce the (typical) algorithmic complexity for "Safety" queries to ~O(1) (with a constant factor determined by the voxel size). Filling of the 3D voxel grid cache for Safety is done on-the-fly (using the BVH once). Ideas for these improvements come from prior work in related libraries such as VecGeom. ----- Implementation details: * The implementation is, for now (until fully tested), provided in a backward compatible manner: - By default, nothing changes - Users have to activate the BVH mode via TGeoParallelWorld::SetAccelerationMode - Users may hence compare the 2 modes or choose the best depending on complexity and needs * Functions for Safety, FindNode, FindBoundary dispatch to some internal implementation. This causes an extra lookup/jump, which can be removed once BVH is fully validated * For the BVH, a well known open source implementation is included in header-only form. The headers are copied from https://github.com/madmann91/bvh commit 66e445b92f68801a6dd8ef943fe3038976ecb4ff. Some minor patching has been done in order to achieve compilation for C++17 (see README). * A new class, TGeoVoxelGrid is provided for the cartesian VoxelGrid container. ---- Performance examples: In a test with the ALICE simulation framework including the ITS + TPC detectors with 48240 volumes on the parallel world, we see * initialization time goes from TGeoVoxelFinder: 10s ---> BVH: 40ms * Geant simulation time: 10s --> 2s * memory usage: 3GB --> 1GB Hence, this PR will make a big difference for the ALICE simulation program. It was verified, that identical results (number of hits, steps, etc) are obtained when going from TGeoVoxelFinder --> BVH+GRID. ---- Outlook: Similar techniques could be applied to ordinary TGeoNavigator routines.
PreviousNext