Skip to content

Commit

Permalink
Merge branch 'main' into geometry-hierarchy-map
Browse files Browse the repository at this point in the history
  • Loading branch information
AJPfleger authored Sep 10, 2024
2 parents 55b5ddb + 415b4e0 commit 13038d3
Show file tree
Hide file tree
Showing 45 changed files with 339 additions and 928 deletions.
4 changes: 2 additions & 2 deletions Core/include/Acts/Geometry/CylinderVolumeStack.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class CylinderVolumeStack : public Volume {
/// @param transform is the new transform
/// @pre The volume bounds need to be of type
/// @c CylinderVolumeBounds.
void update(std::shared_ptr<const VolumeBounds> volbounds,
void update(std::shared_ptr<VolumeBounds> volbounds,
std::optional<Transform3> transform = std::nullopt) override;

/// Update the volume bounds and transform. This
Expand All @@ -100,7 +100,7 @@ class CylinderVolumeStack : public Volume {
/// @param logger is the logger
/// @pre The volume bounds need to be of type
/// @c CylinderVolumeBounds.
void update(std::shared_ptr<const CylinderVolumeBounds> newBounds,
void update(std::shared_ptr<CylinderVolumeBounds> newBounds,
std::optional<Transform3> transform, const Logger& logger);

/// Access the gap volume that were created during attachment or resizing.
Expand Down
8 changes: 3 additions & 5 deletions Core/include/Acts/Geometry/TrackingVolume.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ class TrackingVolume : public Volume {
/// @param volbounds is the description of the volume boundaries
/// @param volumeName is a string identifier
TrackingVolume(const Transform3& transform,
std::shared_ptr<const VolumeBounds> volbounds,
std::shared_ptr<VolumeBounds> volbounds,
const std::string& volumeName = "undefined");

/// Constructor for a full equipped Tracking Volume
Expand All @@ -140,8 +140,7 @@ class TrackingVolume : public Volume {
/// @param denseVolumeVector The contained dense volumes
/// @param volumeName is a string identifier
TrackingVolume(
const Transform3& transform,
std::shared_ptr<const VolumeBounds> volumeBounds,
const Transform3& transform, std::shared_ptr<VolumeBounds> volumeBounds,
std::shared_ptr<const IVolumeMaterial> volumeMaterial,
std::unique_ptr<const LayerArray> staticLayerArray = nullptr,
std::shared_ptr<const TrackingVolumeArray> containedVolumeArray = nullptr,
Expand All @@ -151,8 +150,7 @@ class TrackingVolume : public Volume {
/// Constructor from a regular volume
/// @param volume is the volume to be converted
/// @param volumeName is a string identifier
TrackingVolume(const Volume& volume,
const std::string& volumeName = "undefined");
TrackingVolume(Volume& volume, const std::string& volumeName = "undefined");

// @TODO: This needs to be refactored to include Gen3 volumes
/// Return the associated sub Volume, returns THIS if no subVolume exists
Expand Down
19 changes: 13 additions & 6 deletions Core/include/Acts/Geometry/Volume.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,7 @@ class Volume : public GeometryObject {
///
/// @param transform is the transform to position the volume in 3D space
/// @param volbounds is the volume boundary definitions
Volume(const Transform3& transform,
std::shared_ptr<const VolumeBounds> volbounds);
Volume(const Transform3& transform, std::shared_ptr<VolumeBounds> volbounds);

/// Copy Constructor - with optional shift
///
Expand All @@ -65,20 +64,26 @@ class Volume : public GeometryObject {
/// returns the center of the volume
const Vector3& center() const;

/// Returns const reference to the volume bounds
/// Returns a const reference to the volume bounds
const VolumeBounds& volumeBounds() const;

/// Returns a mutable reference to the volume bounds
VolumeBounds& volumeBounds();

/// Returns shared pointer to the volume bounds
std::shared_ptr<const VolumeBounds> volumeBoundsPtr() const;

/// Returns shared pointer to the volume bounds
std::shared_ptr<VolumeBounds> volumeBoundsPtr();

/// Set volume bounds and update volume bounding boxes implicitly
/// @param volbounds The volume bounds to be assigned
void assignVolumeBounds(std::shared_ptr<const VolumeBounds> volbounds);
void assignVolumeBounds(std::shared_ptr<VolumeBounds> volbounds);

/// Set the volume bounds and optionally also update the volume transform
/// @param volbounds The volume bounds to be assigned
/// @param transform The transform to be assigned, can be optional
virtual void update(std::shared_ptr<const VolumeBounds> volbounds,
virtual void update(std::shared_ptr<VolumeBounds> volbounds,
std::optional<Transform3> transform = std::nullopt);

/// Construct bounding box for this shape
Expand Down Expand Up @@ -117,7 +122,9 @@ class Volume : public GeometryObject {
Transform3 m_transform;
Transform3 m_itransform;
Vector3 m_center;
std::shared_ptr<const VolumeBounds> m_volumeBounds;

private:
std::shared_ptr<VolumeBounds> m_volumeBounds;
};

/**Overload of << operator for std::ostream for debug output*/
Expand Down
22 changes: 8 additions & 14 deletions Core/include/Acts/Propagator/EigenStepper.hpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// This file is part of the Acts project.
//
// Copyright (C) 2016-2022 CERN for the benefit of the Acts project
// Copyright (C) 2016-2024 CERN for the benefit of the Acts project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
Expand All @@ -15,20 +15,18 @@
#include "Acts/Definitions/Tolerance.hpp"
#include "Acts/Definitions/Units.hpp"
#include "Acts/EventData/TrackParameters.hpp"
#include "Acts/EventData/detail/CorrectedTransformationFreeToBound.hpp"
#include "Acts/Geometry/GeometryContext.hpp"
#include "Acts/MagneticField/MagneticFieldContext.hpp"
#include "Acts/MagneticField/MagneticFieldProvider.hpp"
#include "Acts/Propagator/ConstrainedStep.hpp"
#include "Acts/Propagator/DefaultExtension.hpp"
#include "Acts/Propagator/DenseEnvironmentExtension.hpp"
#include "Acts/Propagator/EigenStepperError.hpp"
#include "Acts/Propagator/EigenStepperDefaultExtension.hpp"
#include "Acts/Propagator/PropagatorTraits.hpp"
#include "Acts/Propagator/StepperExtensionList.hpp"
#include "Acts/Propagator/StepperOptions.hpp"
#include "Acts/Propagator/detail/Auctioneer.hpp"
#include "Acts/Propagator/detail/SteppingHelper.hpp"
#include "Acts/Utilities/Intersection.hpp"
#include "Acts/Utilities/Result.hpp"

#include <cmath>
#include <functional>
#include <limits>
#include <type_traits>
Expand All @@ -47,8 +45,7 @@ namespace Acts {
/// with s being the arc length of the track, q the charge of the particle,
/// p the momentum magnitude and B the magnetic field
///
template <typename extensionlist_t = StepperExtensionList<DefaultExtension>,
typename auctioneer_t = detail::VoidAuctioneer>
template <typename extension_t = EigenStepperDefaultExtension>
class EigenStepper {
public:
/// Jacobian, Covariance and State definitions
Expand Down Expand Up @@ -155,11 +152,8 @@ class EigenStepper {
/// The geometry context
std::reference_wrapper<const GeometryContext> geoContext;

/// List of algorithmic extensions
extensionlist_t extension;

/// Auctioneer for choosing the extension
auctioneer_t auctioneer;
/// Algorithmic extension
extension_t extension;

/// @brief Storage of magnetic field and the sub steps during a RKN4 step
struct {
Expand Down
Loading

0 comments on commit 13038d3

Please sign in to comment.