Skip to content

Commit

Permalink
Merge pull request #332 from dmgav/srx-incomplete-scan
Browse files Browse the repository at this point in the history
FIX: fix incorrect number of rows in incomplete scans (SRX)
  • Loading branch information
dmgav authored Dec 13, 2024
2 parents b0fd12a + 4409e8c commit d55ddf0
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pyxrf/model/load_data_from_db.py
Original file line number Diff line number Diff line change
Expand Up @@ -2360,6 +2360,12 @@ def map_data2D_srx_new_tiled(
fast_pos = data_stream0[fast_key]
slow_pos = data_stream0[slow_key]
else:
# Compute the number of actually existing rows in case the scan was interrupted
if d_xs_sum is not None:
slow_pts = d_xs_sum.shape[0]
elif d_xs2_sum is not None:
slow_pts = d_xs2_sum.shape[0]

row_pos_fast = da.arange(fast_pts) * fast_step + fast_start
fast_pos = da.broadcast_to(row_pos_fast, (slow_pts, fast_pts))
if snaking_enabled:
Expand Down

0 comments on commit d55ddf0

Please sign in to comment.