raster auto-center: make vertical line-scan Y padding configurable
The 2nd-stage vertical line scan (n_x=1, height from the ML box) padded its height by a hardcoded 0.10 each side (20% total), which was often too short to cover the whole loop. Read the per-side fraction from daq.auto_raster.line_scan_y_padding_fraction (default 0.15) so it can be tuned per beamline. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
48111e5718
commit
0ac948746a
@@ -56,3 +56,4 @@ daq:
|
||||
auto_raster:
|
||||
loop_face_padding_fraction: 0.15 # pad loop_face raster boxes by 15% per side
|
||||
include_crystal: false # extend the grid to cover crystals outside the loop box
|
||||
line_scan_y_padding_fraction: 0.15 # pad the 2nd-stage vertical line scan height by this per side (10-20%)
|
||||
|
||||
@@ -213,7 +213,7 @@ class RasterService:
|
||||
grid_size_mm: Coordinate,
|
||||
default_n_y: int = 50,
|
||||
y_retarget_threshold_mm: float | None = None,
|
||||
y_padding_fraction_each_side: float = 0.10,
|
||||
y_padding_fraction_each_side: float = 0.15,
|
||||
) -> tuple[SmargonCoordinate, int]:
|
||||
geom = self.ctx.sample_geometry
|
||||
beam_x_pxl = geom.beam_location_pxl.x
|
||||
@@ -799,7 +799,9 @@ class RasterService:
|
||||
geom.beam_size_mm.y * 2.0,
|
||||
grid.grid_size_mm.y * 4.0,
|
||||
),
|
||||
y_padding_fraction_each_side=0.10,
|
||||
y_padding_fraction_each_side=float(
|
||||
cfg_get("daq.auto_raster.line_scan_y_padding_fraction", 0.15)
|
||||
),
|
||||
)
|
||||
|
||||
self.logger.info(
|
||||
|
||||
Reference in New Issue
Block a user