Skip to content

Commit

Permalink
Make sure i0 is increased
Browse files Browse the repository at this point in the history
  • Loading branch information
ChristopherMayes committed Jun 28, 2023
1 parent 7d3a7a6 commit 0066bc6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pmd_beamphysics/interfaces/genesis.py
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,7 @@ def genesis4_par_to_data(h5, species='electron', smear=True):
assert len(current) == 1
# Skip zero current slices. These usually have nans in the particle data.
if current == 0:
i0 += sample
continue

x.append( g['x'][:])
Expand Down

0 comments on commit 0066bc6

Please sign in to comment.