Skip to content

Commit

Permalink
Change logic for number of frames per probe position to match a simil…
Browse files Browse the repository at this point in the history
…ar line later. Its best to keep things consistent.
  • Loading branch information
Peter Ercius ncem-gauss jupyter committed Sep 16, 2024
1 parent 62b9478 commit d9e53ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/stempy/io/sparse_array.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ def from_hdf5(cls, filepath, keep_flyback=True, **init_kwargs):
data = frames[()] # load the full data set
scan_positions = scan_positions_group[()]
else:
num = frames.shape[0] // scan_positions_group.shape[0] # number of frames per probe position
num = frames.shape[0] // np.prod(scan_shape, dtype=int) # number of frames per probe position
data = np.empty(((scan_shape[0]-1) * scan_shape[1] * num), dtype=object)
new_num_cols = scan_shape[0]-1 # number of columns without flyback
for ii in range(scan_shape[1]):
Expand Down

0 comments on commit d9e53ad

Please sign in to comment.