Skip to content

Commit 8d0a74d

Browse files
committed
Merge remote-tracking branch 'upstream/main' into releases
2 parents 061a9d8 + 768427e commit 8d0a74d

File tree

550 files changed

+7407
-5207
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

550 files changed

+7407
-5207
lines changed

.github/workflows/analysis.yml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,69 @@ jobs:
9595
name: coverage-build
9696
path: build
9797

98+
clang_tidy:
99+
runs-on: ubuntu-latest
100+
container: ghcr.io/acts-project/ubuntu2404_clang19:83
101+
102+
steps:
103+
- uses: actions/checkout@v6
104+
with:
105+
fetch-depth: 0
106+
107+
- name: Mark workspace as safe
108+
run: git config --global --add safe.directory /__w/acts/acts
109+
110+
- name: Fetch base branch
111+
if: github.event_name == 'pull_request'
112+
run: git fetch origin "${{ github.base_ref }}"
113+
114+
- uses: astral-sh/setup-uv@v5
115+
116+
- name: Install clang-tidy
117+
run: |
118+
apt-get update && apt-get install -y clang-tidy-19
119+
ln -sf /usr/bin/clang-tidy-19 /usr/bin/clang-tidy
120+
ln -sf /usr/bin/clang++-19 /usr/bin/clang++
121+
ln -sf /usr/bin/clang-19 /usr/bin/clang
122+
123+
- name: Install dependencies
124+
uses: ./.github/actions/dependencies
125+
with:
126+
compiler: clang++
127+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
128+
129+
- name: Configure
130+
run: >
131+
cmake -B build -S .
132+
--preset=gitlab-ci-clangtidy
133+
134+
- name: Run codegen
135+
run: cmake --build build --target ActsCodegen
136+
137+
- name: Analyze (PR - changed files only)
138+
if: github.event_name == 'pull_request'
139+
run: >
140+
uv run CI/clang_tidy/run_clang_tidy_pr.py
141+
analyze build fixes.yml --base-ref "origin/${{ github.base_ref }}"
142+
143+
- name: Analyze (push - all files)
144+
if: github.event_name == 'push'
145+
run: >
146+
uv run CI/clang_tidy/run_clang_tidy_pr.py
147+
analyze build fixes.yml --all
148+
149+
- name: Upload fixes
150+
if: always()
151+
uses: actions/upload-artifact@v6
152+
with:
153+
name: clang-tidy-fixes
154+
path: fixes.yml
155+
156+
- name: Annotate
157+
run: >
158+
uv run CI/clang_tidy/run_clang_tidy_pr.py
159+
annotate fixes.yml
160+
98161
build_performance:
99162
runs-on: ubuntu-latest
100163
container: ghcr.io/acts-project/ubuntu2404:83

.github/workflows/builds.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ jobs:
409409
410410
- name: Build
411411
id: build
412-
uses: addnab/docker-run-action@v3
412+
uses: eic/docker-run-action@v3
413413
continue-on-error: true
414414
with:
415415
image: "ghcr.io/eic/eic_ci_without_acts:nightly"

.github/workflows/update-pip-requirements.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,19 @@ jobs:
1616
# This branch will receive updates each time the workflow runs
1717
# It doesn't matter if it's deleted when merged, it'll be re-created
1818
BRANCH_NAME: auto-dependency-upgrades
19+
PYTHON_VERSION: "3.14"
1920
steps:
2021
- uses: actions/checkout@v6
2122

2223
- name: Set up Python
2324
uses: actions/setup-python@v6
2425
with:
25-
python-version: 3.14
26+
python-version: ${{ env.PYTHON_VERSION }}
2627

27-
- name: Install pip-tools
28-
run: pip install pip-tools
28+
- name: Install uv
29+
run: |
30+
python -m pip install -U pip
31+
python -m pip install -U uv
2932
3033
- name: Compile all requirements.txt
3134
run: |
@@ -38,7 +41,8 @@ jobs:
3841
Examples/Scripts
3942
)
4043
for folder in "${folder_list[@]}"; do
41-
pip-compile "${folder}/requirements.in" > "${folder}/requirements.txt"
44+
rm "${folder}/requirements.txt"
45+
uv pip compile --python-version "$PYTHON_VERSION" "${folder}/requirements.in" -o "${folder}/requirements.txt"
4246
done
4347
4448
- name: Detect changes
@@ -68,7 +72,7 @@ jobs:
6872
PR=$(gh pr list --head $BRANCH_NAME --json number -q '.[0].number')
6973
if [ -z $PR ]; then
7074
gh pr create \
71-
--head $BRANCH_NAME \
75+
--head "$BRANCH_NAME" \
7276
--title "chore: automated python requirements upgrades" \
7377
--body "Full log: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}"
7478
else

.gitlab-ci.yml

Lines changed: 0 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -43,62 +43,6 @@ variables:
4343
- rm -rf spack/.git spack/opt spack/var/spack/cache
4444
- find spack -type f -name "*.pyc" -delete || true
4545

46-
clang_tidy:
47-
stage: build
48-
image: registry.cern.ch/ghcr.io/acts-project/ubuntu2404:83
49-
tags:
50-
- large
51-
artifacts:
52-
paths:
53-
- src/clang-tidy/
54-
when: always
55-
expire_in: 1 week
56-
57-
cache:
58-
- !reference [.spack_cache, cache]
59-
60-
script:
61-
- git clone $CLONE_URL src
62-
- cd src
63-
- git checkout $HEAD_SHA
64-
- >
65-
apt-get update
66-
&& apt-get install -y clang-tidy-18
67-
&& ln -sf /usr/bin/clang++-18 /usr/bin/clang++
68-
&& ln -sf /usr/bin/clang-18 /usr/bin/clang
69-
&& ln -sf /usr/bin/clang-tidy-18 /usr/bin/clang-tidy
70-
71-
- |
72-
CI/dependencies/setup.sh -c clang++ -e .env
73-
source .env
74-
75-
- >
76-
cmake -B build -S .
77-
--preset=gitlab-ci-clangtidy
78-
-DCMAKE_CXX_COMPILER=clang++
79-
-DCMAKE_C_COMPILER=clang
80-
81-
# Main clang-tidy run during cmake compilation
82-
- CI/clang_tidy/run_clang_tidy.sh clang-tidy build
83-
84-
# Install dependencies for processing scripts
85-
- python3 -m pip install -r CI/clang_tidy/requirements.txt
86-
87-
# Parse the main clang-tidy run
88-
- >
89-
CI/clang_tidy/parse_clang_tidy.py
90-
clang-tidy/clang-tidy.log
91-
clang-tidy/clang-tidy.json
92-
--exclude "*thirdparty*"
93-
--exclude "*ActsPodioEdm*"
94-
--exclude "*build/_deps/*"
95-
96-
# Check the combined report against the defined limits
97-
- CI/clang_tidy/check_clang_tidy.py --report clang-tidy/clang-tidy.json --config CI/clang_tidy/limits.yml
98-
99-
after_script:
100-
- !reference [.spack_cleanup, after_script]
101-
10246
build_gnn_cpu:
10347
stage: build
10448
image: registry.cern.ch/ghcr.io/acts-project/ubuntu2404_gnn:83

Alignment/include/ActsAlignment/Kernel/Alignment.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,14 +94,14 @@ struct AlignmentOptions {
9494
///
9595
struct AlignmentResult {
9696
// The change of alignment parameters
97-
Acts::ActsDynamicVector deltaAlignmentParameters;
97+
Acts::DynamicVector deltaAlignmentParameters;
9898

9999
// The aligned parameters for detector elements
100100
std::unordered_map<Acts::SurfacePlacementBase*, Acts::Transform3>
101101
alignedParameters;
102102

103103
// The covariance of alignment parameters
104-
Acts::ActsDynamicMatrix alignmentCovariance;
104+
Acts::DynamicMatrix alignmentCovariance;
105105

106106
// The average chi2/ndf (ndf is the measurement dim)
107107
double averageChi2ONdf = std::numeric_limits<double>::max();

Alignment/include/ActsAlignment/Kernel/Alignment.ipp

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -78,11 +78,10 @@ void ActsAlignment::Alignment<fitter_t>::calculateAlignmentParameters(
7878
alignResult.alignmentDof =
7979
alignResult.idxedAlignSurfaces.size() * Acts::eAlignmentSize;
8080
// Initialize derivative of chi2 w.r.t. alignment parameters for all tracks
81-
Acts::ActsDynamicVector sumChi2Derivative =
82-
Acts::ActsDynamicVector::Zero(alignResult.alignmentDof);
83-
Acts::ActsDynamicMatrix sumChi2SecondDerivative =
84-
Acts::ActsDynamicMatrix::Zero(alignResult.alignmentDof,
85-
alignResult.alignmentDof);
81+
Acts::DynamicVector sumChi2Derivative =
82+
Acts::DynamicVector::Zero(alignResult.alignmentDof);
83+
Acts::DynamicMatrix sumChi2SecondDerivative = Acts::DynamicMatrix::Zero(
84+
alignResult.alignmentDof, alignResult.alignmentDof);
8685
// Copy the fit options
8786
fit_options_t fitOptionsWithRefSurface = fitOptions;
8887
// Calculate contribution to chi2 derivatives from all input trajectories
@@ -134,18 +133,17 @@ void ActsAlignment::Alignment<fitter_t>::calculateAlignmentParameters(
134133
// calculate the covariance of the alignment parameters)
135134
// @TODO: use more stable method for solving the inverse
136135
std::size_t alignDof = alignResult.alignmentDof;
137-
Acts::ActsDynamicMatrix sumChi2SecondDerivativeInverse =
138-
Acts::ActsDynamicMatrix::Zero(alignDof, alignDof);
136+
Acts::DynamicMatrix sumChi2SecondDerivativeInverse =
137+
Acts::DynamicMatrix::Zero(alignDof, alignDof);
139138
sumChi2SecondDerivativeInverse = sumChi2SecondDerivative.inverse();
140139
if (sumChi2SecondDerivativeInverse.hasNaN()) {
141140
ACTS_DEBUG("Chi2 second derivative inverse has NaN");
142141
}
143142

144143
// Initialize the alignment results
145-
alignResult.deltaAlignmentParameters =
146-
Acts::ActsDynamicVector::Zero(alignDof);
144+
alignResult.deltaAlignmentParameters = Acts::DynamicVector::Zero(alignDof);
147145
alignResult.alignmentCovariance =
148-
Acts::ActsDynamicMatrix::Zero(alignDof, alignDof);
146+
Acts::DynamicMatrix::Zero(alignDof, alignDof);
149147
// Solve the linear equation to get alignment parameters change
150148
alignResult.deltaAlignmentParameters =
151149
-sumChi2SecondDerivative.fullPivLu().solve(sumChi2Derivative);

Alignment/include/ActsAlignment/Kernel/detail/AlignmentEngine.hpp

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -35,31 +35,31 @@ struct TrackAlignmentState {
3535
std::size_t alignmentDof = 0;
3636

3737
// The measurements covariance
38-
Acts::ActsDynamicMatrix measurementCovariance;
38+
Acts::DynamicMatrix measurementCovariance;
3939

4040
// The track parameters covariance
41-
Acts::ActsDynamicMatrix trackParametersCovariance;
41+
Acts::DynamicMatrix trackParametersCovariance;
4242

4343
// The projection matrix
44-
Acts::ActsDynamicMatrix projectionMatrix;
44+
Acts::DynamicMatrix projectionMatrix;
4545

4646
// The residual
47-
Acts::ActsDynamicVector residual;
47+
Acts::DynamicVector residual;
4848

4949
// The covariance of residual
50-
Acts::ActsDynamicMatrix residualCovariance;
50+
Acts::DynamicMatrix residualCovariance;
5151

5252
// The chi2
5353
double chi2 = 0;
5454

5555
// The derivative of residual w.r.t. alignment parameters
56-
Acts::ActsDynamicMatrix alignmentToResidualDerivative;
56+
Acts::DynamicMatrix alignmentToResidualDerivative;
5757

5858
// The derivative of chi2 w.r.t. alignment parameters
59-
Acts::ActsDynamicVector alignmentToChi2Derivative;
59+
Acts::DynamicVector alignmentToChi2Derivative;
6060

6161
// The second derivative of chi2 w.r.t. alignment parameters
62-
Acts::ActsDynamicMatrix alignmentToChi2SecondDerivative;
62+
Acts::DynamicMatrix alignmentToChi2SecondDerivative;
6363

6464
// The alignable surfaces on the track and their indices in both the global
6565
// alignable surfaces pool and those relevant with this track
@@ -104,7 +104,7 @@ template <typename traj_t, typename parameters_t = Acts::BoundTrackParameters>
104104
TrackAlignmentState trackAlignmentState(
105105
const Acts::GeometryContext& gctx, const traj_t& multiTraj,
106106
Acts::TrackIndexType entryIndex,
107-
const std::pair<Acts::ActsDynamicMatrix,
107+
const std::pair<Acts::DynamicMatrix,
108108
std::unordered_map<std::size_t, std::size_t>>&
109109
globalTrackParamsCov,
110110
const std::unordered_map<const Acts::Surface*, std::size_t>&
@@ -170,20 +170,19 @@ TrackAlignmentState trackAlignmentState(
170170
// Initialize the alignment matrices with components from the measurement
171171
// states
172172
// The measurement covariance
173-
alignState.measurementCovariance = Acts::ActsDynamicMatrix::Zero(
173+
alignState.measurementCovariance = Acts::DynamicMatrix::Zero(
174174
alignState.measurementDim, alignState.measurementDim);
175175
// The bound parameters to measurement projection matrix
176-
alignState.projectionMatrix = Acts::ActsDynamicMatrix::Zero(
176+
alignState.projectionMatrix = Acts::DynamicMatrix::Zero(
177177
alignState.measurementDim, alignState.trackParametersDim);
178178
// The derivative of residual w.r.t. alignment parameters
179-
alignState.alignmentToResidualDerivative = Acts::ActsDynamicMatrix::Zero(
179+
alignState.alignmentToResidualDerivative = Acts::DynamicMatrix::Zero(
180180
alignState.measurementDim, alignState.alignmentDof);
181181
// The track parameters covariance
182-
alignState.trackParametersCovariance = Acts::ActsDynamicMatrix::Zero(
182+
alignState.trackParametersCovariance = Acts::DynamicMatrix::Zero(
183183
alignState.trackParametersDim, alignState.trackParametersDim);
184184
// The residual
185-
alignState.residual =
186-
Acts::ActsDynamicVector::Zero(alignState.measurementDim);
185+
alignState.residual = Acts::DynamicVector::Zero(alignState.measurementDim);
187186

188187
// Unpack global track parameters covariance and the starting row/column for
189188
// all smoothed states.
@@ -203,13 +202,13 @@ TrackAlignmentState trackAlignmentState(
203202
iMeasurement -= measdim;
204203
iParams -= Acts::eBoundSize;
205204
// (a) Get and fill the measurement covariance matrix
206-
const Acts::ActsDynamicMatrix measCovariance =
205+
const Acts::DynamicMatrix measCovariance =
207206
state.effectiveCalibratedCovariance();
208207
alignState.measurementCovariance.block(iMeasurement, iMeasurement, measdim,
209208
measdim) = measCovariance;
210209

211210
// (b) Get and fill the bound parameters to measurement projection matrix
212-
const Acts::ActsDynamicMatrix H =
211+
const Acts::DynamicMatrix H =
213212
state.projectorSubspaceHelper().fullProjector().topLeftCorner(
214213
measdim, Acts::eBoundSize);
215214
alignState.projectionMatrix.block(iMeasurement, iParams, measdim,
@@ -277,11 +276,11 @@ TrackAlignmentState trackAlignmentState(
277276
alignState.measurementCovariance.inverse() *
278277
alignState.residual;
279278
alignState.alignmentToChi2Derivative =
280-
Acts::ActsDynamicVector::Zero(alignState.alignmentDof);
281-
alignState.alignmentToChi2SecondDerivative = Acts::ActsDynamicMatrix::Zero(
279+
Acts::DynamicVector::Zero(alignState.alignmentDof);
280+
alignState.alignmentToChi2SecondDerivative = Acts::DynamicMatrix::Zero(
282281
alignState.alignmentDof, alignState.alignmentDof);
283282
// The covariance of residual
284-
alignState.residualCovariance = Acts::ActsDynamicMatrix::Zero(
283+
alignState.residualCovariance = Acts::DynamicMatrix::Zero(
285284
alignState.measurementDim, alignState.measurementDim);
286285
alignState.residualCovariance = alignState.measurementCovariance -
287286
alignState.projectionMatrix *

CI/clang_tidy/filter.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Exclusion filters for CI/clang_tidy/annotate.py
2+
#
3+
# Diagnostics whose file path matches any of these regexes are dropped
4+
# and do NOT gate the job or produce annotations.
5+
6+
exclude_path_regexes:
7+
# Third-party / vendored code
8+
- (^|/)thirdparty/
9+
- (^|/)third_party/
10+
11+
# Generated PODIO EDM
12+
- ActsPodioEdm
13+
- EDM4hep/generated
14+
15+
# Generated ROOT dictionaries
16+
- Dict.cxx$
17+
18+
# Build-tree dependencies fetched by CMake
19+
- (^|/)build/_deps/
20+
21+
# System / external headers that may leak into diagnostics
22+
- ^/usr/
23+
- ^/opt/
24+
- ^/cvmfs/
25+
26+
# Severity for GitHub annotations ("error" or "warning")
27+
severity: error

0 commit comments

Comments
 (0)