Commit 6e3db3a
feat: move ROOT surface material map I/O to plugins (acts-project#4400)
This PR moves the I/O for material map reading/writing into
`Plugins/Root` and removes the duplicated code from `RootMaterialWriter`
and `RootMaterialDecorator`.
It also harmonizes the usage/definition of `SurfaceMaterialMaps`.
`VolumeMaterialMaps`, and `DetectorMaterialMaps` consistently by
declaring them once.
It is backward compatible, and introduces a new, common ROOT I/O
material backend that can be shared between all material classes
(homongeneous, binned, grid, indexed).
This PR also allows UnitTests to be added for Material writing, the
first ones are done with it, and it removes roughly 100 SonarCloud
issues, mainly related to how we call and use ROOT.
This will be followed by a PRs doing the same for Volume material and
updated Grid based surface material.
The reading gis kept backward-compatible.
--- END COMMIT MESSAGE ---
Any further description goes here, @-mentions are ok here!
- Use a *conventional commits* prefix: [quick
summary](https://www.conventionalcommits.org/en/v1.0.0/#summary)
- We mostly use `feat`, `fix`, `refactor`, `docs`, `chore` and `build`
types.
- A milestone will be assigned by one of the maintainers
---------
Co-authored-by: Paul Gessinger <hello@paulgessinger.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>1 parent d74bed0 commit 6e3db3a
File tree
31 files changed
+1712
-1059
lines changed- Core
- include/Acts/Material
- src/Material
- Examples
- Algorithms/MaterialMapping
- include/ActsExamples/MaterialMapping
- src
- Io
- Json
- include/ActsExamples/Io/Json
- src
- Root
- include/ActsExamples/Io/Root
- src
- Python
- src
- tests
- Plugins
- Json
- include/Acts/Plugins/Json
- src
- Root
- include/Acts/Plugins/Root
- src
- Tests/UnitTests/Plugins/Root
31 files changed
+1712
-1059
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | 28 | | |
36 | 29 | | |
37 | 30 | | |
| |||
83 | 76 | | |
84 | 77 | | |
85 | 78 | | |
86 | | - | |
| 79 | + | |
87 | 80 | | |
88 | 81 | | |
89 | 82 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
| 82 | + | |
83 | 83 | | |
84 | 84 | | |
85 | | - | |
| 85 | + | |
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
| |||
Lines changed: 3 additions & 18 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
| 12 | + | |
29 | 13 | | |
30 | 14 | | |
31 | 15 | | |
| |||
40 | 24 | | |
41 | 25 | | |
42 | 26 | | |
43 | | - | |
| 27 | + | |
| 28 | + | |
44 | 29 | | |
45 | 30 | | |
46 | 31 | | |
Lines changed: 1 addition & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | 44 | | |
48 | 45 | | |
49 | 46 | | |
| |||
276 | 273 | | |
277 | 274 | | |
278 | 275 | | |
279 | | - | |
| 276 | + | |
280 | 277 | | |
281 | 278 | | |
282 | 279 | | |
| |||
Lines changed: 1 addition & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
| |||
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
35 | | - | |
36 | 36 | | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | 37 | | |
48 | 38 | | |
49 | 39 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
| 52 | + | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| |||
Lines changed: 3 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
27 | 28 | | |
28 | 29 | | |
29 | 30 | | |
30 | | - | |
31 | 31 | | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | 32 | | |
43 | 33 | | |
44 | 34 | | |
| |||
79 | 69 | | |
80 | 70 | | |
81 | 71 | | |
82 | | - | |
| 72 | + | |
| 73 | + | |
83 | 74 | | |
84 | 75 | | |
85 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| |||
0 commit comments