Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Aug 22, 2024
1 parent b371c1e commit 8827a29
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Examples/Tests/collision/analysis_collision_1d.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@

# Separate macroparticles from group A (low weight) and group B (high weight)
# by sorting based on weight
sorted_indices = data['ions','particle_weight'].argsort()
sorted_wp = data['ions', 'particle_weight'][sorted_indices].value
sorted_px = data['ions', 'particle_momentum_x'][sorted_indices].value
sorted_py = data['ions', 'particle_momentum_y'][sorted_indices].value
sorted_pz = data['ions', 'particle_momentum_z'][sorted_indices].value
sorted_indices = data["ions", "particle_weight"].argsort()
sorted_wp = data["ions", "particle_weight"][sorted_indices].value
sorted_px = data["ions", "particle_momentum_x"][sorted_indices].value
sorted_py = data["ions", "particle_momentum_y"][sorted_indices].value
sorted_pz = data["ions", "particle_momentum_z"][sorted_indices].value

# Find the index 'Npmin' that separates macroparticles from group A and group B
Np = len(sorted_wp)
Expand Down

0 comments on commit 8827a29

Please sign in to comment.