File MeasurementHelpers.hpp

namespace Acts

Note

This file is foreseen for the Geometry module to replace Extent

Functions

template<typename L, typename A, typename B>
auto visit_measurement(A &&param, B &&cov, size_t dim, L &&lambda)

Dispatch a lambda call on an overallocated parameter vector and covariance matrix, based on a runtime dimension value.

Inside the lambda call, the vector and matrix will have fixed dimensions, but will still point back to the originally given overallocated values.

Note

No requirements on A and B are made, to enable a single overload for both const and non-const matrices/vectors.

Template Parameters
  • L – The lambda type

  • A – The parameter vector type

  • B – The covariance matrix type

Parameters
  • param – The parameter vector

  • cov – The covariance matrix

  • dim – The actual dimension as a runtime value

  • lambda – The lambda to call with the statically sized subsets

template<typename L>
auto visit_measurement(size_t dim, L &&lambda)

Dispatch a generic lambda on a measurement dimension.

This overload doesn’t assume anything about what is needed inside the lambda, it communicates the dimension via an integral constant type

Template Parameters

L – The generic lambda type to call

Parameters
  • dim – The runtime dimension of the measurement

  • lambda – The generic lambda instance to call

Returns

Returns the lambda return value