Skip to content

feat(bic): flat imaging staves on alternating rails, carbon side walls, drawing scripts - #1200

Merged
sly2j merged 10 commits into
mainfrom
feat-bic-flat-staggered-staves
Oct 29, 2026
Merged

sly2j merged 10 commits into
mainfrom
feat-bic-flat-staggered-staves

Conversation

@sly2j

@sly2j sly2j commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Briefly, what does this PR introduce? Please link to any relevant presentations or discussions.

Updates the BIC imaging layers (epic_EcalBarrelImaging) towards the current engineering design. Main changes:

  1. Flat, alternating staves. The 10° stave tilt is replaced by 0° (flat, parallel to the sector bottom). Neighbouring staves alternate between a low and a high rail (4.0 / 6.55 mm above the inner plate; EcalBarrel_StaveRail_low, EcalBarrel_StaveRail_gap), so they overlap in phi without touching. Sensors face inward. Stave counts are configurable per layer (6, 6, 6, 7, 7, 7); layer 4 gets a 7th stave to close a gap in active-silicon coverage.
  2. Carbon-fiber frame to the current engineering design. Top/bottom plates 1.5 mm (was 2.0 mm), new 1 mm side walls, 14 mm inside envelope; total layer thickness is unchanged. The outer plate now spans the full layer width. Staves keep a 0.5 mm clearance to the walls at the point of closest approach.
  3. Drawing scripts to examine the structure from the loaded geometry: scripts/subdetector_tests/draw_bic_imaging_sector.py (sector cross-sections) and render_bic_imaging_3d.py (3D view).

Out of scope (follow-up PRs): realistic module structure; mechanical supports (trays) for the AstroPix modules.

Validation: TGeo and Geant4 overlap checks (as in CI) give 0 overlaps on craterlake, ip6_extended and inner_detector; the ACTS geometry check passes; stack height and all other layers are unchanged. Active-silicon overlap in coverage in phi between neighboring staves is 2.8 / 1.8 / 0.7 / 3.1 / 2.2 / 1.4 mm for layers 1 to 6.

Figures

  • Before / after cross-section of layer 2 (zoom)
before_zoom after_zoom - All layers cross-section, new geometry after_all - 3D render, slice of layers 2 and 3 render3d_layers2-3

What is the urgency of this PR?

  • High (please describe reason below)
  • Medium
  • Low

What kind of change does this PR introduce?

  • Bug fix (issue #__)
  • New feature (issue #__)
  • Optimization (issue #__)
  • Updated constants (issue #__)
  • Updated documentation
  • other: __

Please check if any of the following apply

  • This PR introduces breaking changes. Please describe changes users need to make below.
  • This PR changes default behavior. Please describe changes below.
  • AI was used in preparing this PR. Please describe usage below.

The BIC imaging geometry changes as described above (tilt removed, new frame, layer 4 has 7 staves). AI (Claude) assisted with implementation, validation and this description.

sly2j and others added 8 commits October 28, 2026 03:19
…rop stave offset

Read the frame height and thickness once per layer before the stave loop so the stave
placement can use them, guard the stave pitch for repeat=1 (a single stave is centred), and
remove the unused stave offset attribute and the layer_j sign flips. No change to the
geometry for the existing compact files.

Co-Authored-By: Supervisor for Claude
Replace the common 10 degree tilt of the AstroPix staves by flat staves parallel to the sector
bottom, sensors facing inward. Neighbouring staves alternate between a low and a high rail
(EcalBarrel_StaveRail_low/high = 1.0/6.4 mm above the inner carbon plate; rails are not
modelled), the first stave being low. Stave counts per layer become constants
(EcalBarrel_StavesN_layer1..6 = 6,6,6,7,7,7; only layer 4 gains a stave, closing a gap in
active-silicon phi coverage). The plugin throws if staves overlap on one tier, hit the outer
plate or the sector walls. Drop the stave angle attribute and tilt constant.

Co-Authored-By: Supervisor for Claude
… low stave

Co-Authored-By: Supervisor for Claude
frame_outer was built with the inner plate's trapezoid half-widths, so it was
about 1 mm narrower per side than the layer and did not cover the side-wall
tops. Use the plate's own radial heights.

Co-Authored-By: Supervisor for Claude
The wall inner face is slanted, so the outermost low stave is closest to it at
its bottom outer corner. Place the outermost staves so the perpendicular
distance from that corner to the inner-face plane is wall_gap, and evaluate the
fit check on the same quantity. EcalBarrel_StaveWall_gap 0.2 -> 0.5 mm.

Co-Authored-By: Supervisor for Claude
Add scripts/subdetector_tests/draw_bic_imaging_sector.py (x-radial cross-sections of the BIC imaging layers from the loaded TGeo geometry, with an annotated zoom at the sector wall) and scripts/subdetector_tests/render_bic_imaging_3d.py (z-buffer 3D render of selected imaging layers). Both take -c/-o and run on the normal install.

Co-Authored-By: Supervisor for Claude
@github-actions github-actions Bot added topic: infrastructure Regarding build system, CI, CD topic: barrel Mid-rapidity detectors topic: calorimetry labels Oct 28, 2026
@sly2j
sly2j requested review from mariakzurek, veprbl and wdconinc and a balanced review from Copilot October 28, 2026 15:12
@sly2j
sly2j marked this pull request as ready for review October 28, 2026 15:13
Comment thread scripts/subdetector_tests/bic/draw_bic_imaging_sector.py

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Skipping a stave prevents stave_idx from incrementing, causing subsequent staves to receive incorrect rail assignments, colors, and labels.

1 open issue
What changed in this PR

Updates the BIC imaging calorimeter geometry toward the current engineering design and adds tools to visualize the loaded geometry.

Changes:

  • Replaces tilted staves with flat, alternating rail placements and configurable per-layer counts, adding a seventh stave to layer 4.
  • Uses thinner carbon plates, adds side walls, and checks stave fit while preserving layer thickness.
  • Adds sector cross-section drawings and 3D rendering scripts.
File Description
src/​BarrelCalorimeterImaging_geo.cpp Implements alternating stave placement, fit checks, and revised carbon framing.
scripts/​subdetector_tests/​render_bic_imaging_3d.py Adds windowed 3D rendering of imaging layers.
scripts/​subdetector_tests/​draw_bic_imaging_sector.py Adds layer cross-sections and annotated clearance views.
compact/​ecal/​bic/​bic.xml Configures rails, walls, and stave counts for all imaging layers.
compact/​ecal/​bic/​bic_layer1_only.xml Applies the updated geometry parameters to the layer-1-only configuration.

Review effort: Balanced

Comment thread scripts/subdetector_tests/bic/render_bic_imaging_3d.py
sly2j added 2 commits October 28, 2026 15:28
Skipped volumes no longer shift the rail parity (colour/label) of later staves; the per-layer counter reset and the per-stave increment now run before the skip filter.

Co-Authored-By: Supervisor for Claude

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

No active review issues are reported for the BIC imaging geometry and visualization updates.

No open issues 🎉

1 resolved since last review

Review effort: Balanced

@wdconinc wdconinc left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. The only issue could be that the scripts are untested code that could start to diverge in assumptions from what's in the geometry. I think we can tolerate that in the scripts/ directory (or at least we currently do).

@veprbl veprbl left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All fine in capybara.

@sly2j
sly2j removed the request for review from mariakzurek October 28, 2026 21:14
@sly2j
sly2j added this pull request to the merge queue Oct 29, 2026
Merged via the queue into main with commit ce6514c Oct 29, 2026
131 of 133 checks passed
@sly2j
sly2j deleted the feat-bic-flat-staggered-staves branch October 29, 2026 13:07

This branch was successfully deployed

1 active deployment
github-pages — 017b0ebc Deployed Oct 28, 2026 by sly2j via deploy-artifacts-page #6173
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic: barrel Mid-rapidity detectors topic: calorimetry topic: infrastructure Regarding build system, CI, CD

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants