Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor!: Remove navigator layer bounds check option #2851

Merged
Merged
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
5 changes: 0 additions & 5 deletions Core/include/Acts/Propagator/Navigator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,6 @@ class Navigator {
bool resolveMaterial = true;
/// stop at every surface regardless what it is
bool resolvePassive = false;

/// Whether to perform boundary checks for layer resolving (improves
/// navigation for bended tracks)
BoundaryCheck boundaryCheckLayerResolving = BoundaryCheck(true);
};

/// @brief Nested State struct
Expand Down Expand Up @@ -1187,7 +1183,6 @@ class Navigator {
// Create the navigation options
// - and get the compatible layers, start layer will be excluded
NavigationOptions<Layer> navOpts;
navOpts.boundaryCheck = m_cfg.boundaryCheckLayerResolving;
navOpts.resolveSensitive = m_cfg.resolveSensitive;
navOpts.resolveMaterial = m_cfg.resolveMaterial;
navOpts.resolvePassive = m_cfg.resolvePassive;
Expand Down
37 changes: 0 additions & 37 deletions Tests/IntegrationTests/PropagationBentTracks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,25 +89,6 @@ BOOST_AUTO_TEST_CASE(with_boundary_check_no_bfield) {
0);
}

BOOST_AUTO_TEST_CASE(without_boundary_check_no_bfield) {
auto navCfg = Acts::Navigator::Config{};
navCfg.boundaryCheckLayerResolving = Acts::BoundaryCheck(false);
const auto xPositions = xPositionsOfPassedSurfaces(navCfg, 0.0_T);

// without bField we exit at the side so we don't hit the surfaces at x ~
// 2000 and also not the boundary surface at x = 3000, regardless of the
// boundary checking
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 999.0), 1);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 1001.0),
1);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 1999.0),
0);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 2001.0),
0);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 3000.0),
0);
}

BOOST_AUTO_TEST_CASE(with_boundary_check_with_bfield) {
auto navCfg = Acts::Navigator::Config{};
const auto xPositions = xPositionsOfPassedSurfaces(navCfg, 0.5_T);
Expand All @@ -124,21 +105,3 @@ BOOST_AUTO_TEST_CASE(with_boundary_check_with_bfield) {
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 3000.0),
1);
}

BOOST_AUTO_TEST_CASE(no_boundary_check_with_bfield) {
auto navCfg = Acts::Navigator::Config{};
navCfg.boundaryCheckLayerResolving = Acts::BoundaryCheck(false);
const auto xPositions = xPositionsOfPassedSurfaces(navCfg, 0.5_T);

// Without boundary check at layer resolving, we also hit the surfaces at x ~
// 2000
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 999.0), 1);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 1001.0),
1);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 1999.0),
1);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 2001.0),
1);
BOOST_CHECK_EQUAL(std::count(xPositions.begin(), xPositions.end(), 3000.0),
1);
}
Loading