Skip to content

Commit

Permalink
Fix pulse slicing code to advance to next train on same pulse ID
Browse files Browse the repository at this point in the history
  • Loading branch information
philsmt committed Nov 20, 2024
1 parent df2e03a commit 707eb58
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Fixed:
- [`Scan.plot_bin_by_steps()`][extra.components.Scan.plot_bin_by_steps] would
previously ignore the `title`/`xlabel`/`ylabel` arguments, now it actually
uses them (!237).
- [`AdqRawChannel.pulse_data()`][extra.components.AdqRawChannel.pulse_data] no longer erroneously reads in the same train data for every pulse if there is only a single pulse per train.

Changed:
- [`gaussian()`][extra.utils.gaussian] has a new `norm` parameter to allow
Expand Down
4 changes: 2 additions & 2 deletions src/extra/components/_adq.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ def _reshape_flat_pulses(
for i in range(pulse_ids.shape[0]):
cur_pid = pulse_ids[i]

if cur_pid < prev_pid:
# Pulse ID decreasing means a new train started.
if cur_pid <= prev_pid:
# Pulse ID not increasing means a new train started.
pid_offset = cur_pid
j += 1

Expand Down

0 comments on commit 707eb58

Please sign in to comment.